Added database support.

Databases still in development.