Fixed minor issues in  DBHandler