Change the way of reading from database.