Added database stuff

...does not work on my machine with local database, but works on remote
database.