Uncommented the database functions