We're updating the issue view to help you get more done. 

Problems with rollback on sqlFile changes

Description

reported in: http://liquibase.org/forum/index.php?topic=126.0

I have found, firstly, the real culprit, a previous change that used SqlFile (it's hard to see which change gives an error sometimes). The situation is pretty much the same, but simpler, and I've tried some variations. Here's the original:

Code:

<?xml version="1.0" encoding="UTF-8"?>
<databaseChangeLog
xmlns="http://www.liquibase.org/xml/ns/dbchangelog/1.9"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog/1.9 http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-1.9.xsd">
<changeSet author="ruby" id="1" >
<sqlFile stripComments="true" path="r5/OpenCity-createTables.sql"/>
<sqlFile stripComments="true" path="r5/OpenCity-insertData.sql"/>
<rollback>
<sqlFile stripComments="true" path="r5/OpenCity-rollback.sql"/>
</rollback>
</changeSet>
</databaseChangeLog>

I've tried with two separate changesets, with one rollback file for each SQL file, and finally with just one file:

Code:

<?xml version="1.0" encoding="UTF-8"?>
<databaseChangeLog
xmlns="http://www.liquibase.org/xml/ns/dbchangelog/1.9"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog/1.9 http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-1.9.xsd">
<changeSet author="ruby" id="1" >
<sqlFile stripComments="true" path="r5/OpenCity-createTables.sql"/>
<rollback>
<sqlFile stripComments="true" path="r5/OpenCity-rollback.sql"/>
</rollback>
</changeSet>
</databaseChangeLog>

Still get the same issue. Since we haven't started doing a lot of changes yet, it hasn't been much of a problem so far, but it will be.

Environment

None

Status

Assignee

Nathan Voxland

Reporter

Nathan Voxland

Labels

None

Fix versions

Affects versions

1.9.4

Priority

Major