Fixed the database schema