Migrates the DB