Implemented fetching the DB