Added some functionality to the database, all implemented functions are
working now at least :)