Finished all functions in the DB class