loader and adapter for the the data from database to view.