Database working and populating main screen