Case sensitivity issue with tableExists precondition



we have tested LB 3.0.7 (using Ant 1.8.2) with our scripts (in order to upgrade from LB 2.0.1) against MSSQL 2008 R2 (v10.50.4000.0) and found following error:

Error executing SQL CREATE TABLE [dbo].[Table] ([Column1] VARCHAR(50) NOT NULL, [Column2] BIGINT NOT NULL, [Column3] BIGINT NOT NULL, CONSTRAINT [PK_Table] PRIMARY KEY ([Column1])); This table already exists.
This error should have been handled in our scripts by the following expression:
<preConditions onFail="error_handling">
<tableExists schemaName="${liquibase.meta.schema}" tableName="Table"/>

So it seems the precondition tableExists doesnt work with LB 3.0.7 in this case.
The scripts work fine with LB 2.0.1.


I am running into this same problem with Oracle. When I changed the property to be the schema name in all caps, it works correctly. I compared to 2.0.5, and I did not need the schema name to be in all caps.


MSSQL, Oracle


Nathan Voxland

Fix versions

Affects versions