Removed the variable allocation for the db.

There's no need to allocate a variable for the database connection; also
cleaned up some alignment in schema definitions.