Grails支持自动迁移(Grails 2.2.2)

Grails支持自动迁移(Grails 2.2.2),grails,gorm,grails-plugin,grails-2.0,Grails,Gorm,Grails Plugin,Grails 2.0,我正在测试Grails作为我们工作场所的潜在框架。我使用Grails网站上的本教程来管理数据库: 我一直能够成功地遵循以下步骤: 启用自动迁移 之后,如果我使用grails run app重新启动服务器,我会收到一条长错误消息,开头是: Error 2013-06-13 12:03:39,639 [localhost-startStop-1] ERROR context.GrailsContextLoader - Error initializing the application: liqu

我正在测试Grails作为我们工作场所的潜在框架。我使用Grails网站上的本教程来管理数据库:

我一直能够成功地遵循以下步骤:

启用自动迁移

之后,如果我使用grails run app重新启动服务器,我会收到一条长错误消息,开头是:

Error 2013-06-13 12:03:39,639 [localhost-startStop-1] ERROR context.GrailsContextLoader - Error initializing the application: liquibase.exception.MigrationFailedException: Migration failed for change set 2012-02-01-initial-database.groovy::1371149615719-2::jable (generated):

Error: Error executing SQL ALTER TABLE BOOK DROP COLUMN VERSION: Cannot
drop last column "VERSION"; SQL statement:
ALTER TABLE BOOK DROP COLUMN VERSION [90084-164]
Message: Error executing SQL ALTER TABLE BOOK DROP COLUMN VERSION: Cannot drop last column "VERSION"; SQL statement:
ALTER TABLE BOOK DROP COLUMN VERSION [90084-164]
.......不停地


知道为什么吗?

使用run-app命令时,您似乎试图删除并创建数据库。检查您的DataSource.groovy,environments->development->DataSource->dbCreate。是否value=“update”?另请参见和