我创建了一个Rails数据库迁移,以将一个新列添加到我的数据库中的一个表中,但是当我注意到它花费的时间比预期的长很多(15分钟以上)之后,我手动地杀死了运行迁移的ruby进程。然后我意识到,由于表中的数据量,运行时并不是很平常,所以我再次启动了它。现在我得到了错误:
Mysql::Error: Duplicate column name 'new_column': ALTER TABLE `table_name`
我的数据库名称是SPM,我想将其更改为spm (小写字母)。ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQLserver version for the right syntax to use near 'DATABASE SPM to spm' at line 1
我的服务器版本: 5.0.45