Hi Nathan,
I checked issue #1 and it is fixed… I’m using revision 1666.
Now I found why is issue #2, and I think it might be a problem in some cases (I can actually solve it in my case):
In RC2 white spaces at the end of the file are used for the check-sum calculation. while in RC3+ they are trimmed and ignored.
Here you have the case for this sqlfile:
insert into test_table values(1, 'hello');
insert into test_table values(2, 'hello');
RC2 (my build before RC3)
[exec] – *********************************************************************
[exec] – Update Database Script
[exec] – *********************************************************************
[exec] – Change Log: test.xml
[exec] – Ran at: 8/4/10 12:35 PM
[exec] – Against: db@jdbc:oracle:thin:@client:1521:orcl
[exec] – Liquibase version: 2.0-rc3-SNAPSHOT
[exec] – *********************************************************************
[exec] – Lock Database
[exec] – Changeset test.xml::test-inserts::alexis::(Checksum: 2:c253005ae54a10dfd5481e7476112dd5)
[exec] DELETE FROM test_table;
[exec] insert into test_table values(1, ‘hello’);
[exec] insert into test_table values(2, ‘hello’);
[exec] INSERT INTO DATABASECHANGELOG (AUTHOR, COMMENTS, DATEEXECUTED, DESCRIPTION, EXECTYPE, FILENAME, ID, LIQUIBASE, MD5SUM, ORDEREXECUTED) VALUES (‘alexis’, NULL, SYSTIMESTAMP, ‘Delete Data, SQL From File’, ‘EXECUTED’, ‘test.xml’, ‘test-inserts’, ‘2.0-rc3-SNP’, ‘2:c253005ae54a10dfd5481e7476112dd5’, 289);
[exec] – Release Database Lock
RC6:
[exec] – *********************************************************************
[exec] – Update Database Script
[exec] – *********************************************************************
[exec] – Change Log: test.xml
[exec] – Ran at: 8/4/10 12:29 PM
[exec] – Against: db@jdbc:oracle:thin:@client:1521:orcl
[exec] – Liquibase version: 2.0-rc6-SNAPSHOT
[exec] – *********************************************************************
[exec] Aug 4, 2010 12:29:50 PM liquibase.logging.jvm.JavaUtilLogger info
[exec] INFO: Successfully released change log lock
[exec] – Lock Database
[exec] – Changeset test.xml::test-inserts::alexis::(Checksum: 2:a26beb9bad1a08e5461de1271fd7fcb5)
[exec] DELETE FROM test_table;
[exec] insert into test_table values(1, ‘hello’);
[exec] insert into test_table values(2, ‘hello’);
[exec] INSERT INTO DATABASECHANGELOG (AUTHOR, COMMENTS, DATEEXECUTED, DESCRIPTION, EXECTYPE, FILENAME, ID, LIQUIBASE, MD5SUM, ORDEREXECUTED) VALUES (‘alexis’, NULL, SYSTIMESTAMP, ‘Delete Data, SQL From File’, ‘EXECUTED’, ‘test.xml’, ‘test-inserts’, ‘2.0-rc6-SNP’, ‘2:a26beb9bad1a08e5461de1271fd7fcb5’, 289);
[exec] – Release Database Lock
Empty lines at the middle of the sentences are correctly included in the check-sum calculation.
Which behavior should we spect for future releases?. Because a changeset will fail if it has empy lines at the end of the file and hasn’t runonChange=“true”
Hope this helps,
Alexis