Adding some features to the Database class