Finished initial buildout of database.py