Added ability to upgrade or downgrade database.