Value 'CONTINUE' is not facet-valid error on running liquibase

不想你离开。 提交于 2019-12-24 08:30:05

问题


When i try to run the following command:

java -jar liquibase-3.4.1.jar --classpath=postgresql-9.2-1004.jdbc4.jar --logLevel=severe --url=jdbc:postgresql://localhost/raritan --username=<USER>--password=<PWD> --changeLogFile=master_changelog.xml update

I get the following exception:

    SEVERE 8/29/16 12:46 PM: liquibase: Error parsing line 7 column 35 of changelogdropViews.xml: cvc-enumeration-valid: Value 'CONTINUE' is not facet-valid withespect to enumeration '[HALT, WARN]'. It must be a value from the enumeration. liquibase.exception.ChangeLogParseException: iquibase.exception.SetupException
 Error parsing line 7 column 35 of changelog_dropViews.xml: cvc-enumeration-val
d: Value 'CONTINUE' is not facet-valid with respect to enumeration '[HALT, WARN
'. It must be a value from the enumeration.

This is my changelog file:

    <?xml version="1.0" ?>
<databaseChangeLog
        xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-2.0.xsd">

    <preConditions onFail="CONTINUE">
            <sqlCheck expectedResult="1">select count(1) from pg_extension where extname='plsh'</sqlCheck>
    </preConditions>

回答1:


See the documentation for preconditions: http://www.liquibase.org/documentation/preconditions.html

There it says:

Outside a changeset (e.g. at the beginning of the change log), only HALT and WARN are possible values.



来源:https://stackoverflow.com/questions/39211306/value-continue-is-not-facet-valid-error-on-running-liquibase

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!