3 回答

TA贡献1821条经验 获得超4个赞
问题在于on-fail属性拼写不正确。on-fail应该是onFail。
最好将先决条件置于特定更改集的范围内,并且注释应该在先决条件之后进行,尽管这不是这里的问题。
databaseChangeLog:
- changeSet:
id: zzchange-1.0-remove-xczczxc
author: zzzz
preConditions:
onFail: mark_ran
tableExists:
tableName: some_old_table
comment: Remove some_old_table table - no longer needed
changes:
- dropTable:
tableName: some_old_table

TA贡献1866条经验 获得超5个赞
在你的第二次尝试中,在你的先决条件之后发表你的评论
databaseChangeLog:
- changeSet:
id: zzchange-1.0-remove-xczczxc
author: zzzz
preConditions:
on-fail: mark_ran
tableExists:
tableName: some_old_table
comment: Remove some_old_table table - no longer needed
changes:
- dropTable:
tableName: some_old_table
我不太确定为什么您的第一次尝试行不通,但是我认为拥有全局先决条件不是一个好主意。这是因为他们在同一文档中所说的:
Preconditions at the changelog level apply to all changesets, not just those listed in the current changelog or its child changelogs.
添加回答
举报