Methods for DB access and test case for reading JSON.