dropDefaultValue doesn't take the schema into account for MS SQL Server


I’m still trying to migrate from version 2.0.5 to version 3.0.7 and I encounter some trouble with the dropDefaultValue change on MS SQL Server.

Trying to execute

works well with version 2 but with version 3, I get
  1. Change Set liquibase/155.xml::201103221000-3::HVS failed.  Error: Error executing SQL DECLARE @default sysname
  2. SELECT @default = object_name(default_object_id) FROM sys.columns WHERE object_id=object_id(‘null.ASSUR’) AND name='TX_VERS_E’
  3. EXEC ('ALTER TABLE [BIG_TEST].[ASSUR] DROP CONSTRAINT ’ + @default): Syntaxe incorrecte vers ‘CONSTRAINT’.
  4. com.microsoft.sqlserver.jdbc.SQLServerException: Syntaxe incorrecte vers ‘CONSTRAINT’.
  5.     at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:216) ~[sqljdbc4-4.0.2206.100.jar:na]
  6.     …
It appears that setting the @default variable relies on a request where the prefix to the table is not set. Thus, null is printed instead of the default schema name and the request fails.

Can it be fixed in a coming version ?

Thanks by advance


I saw it is already referenced as CORE-1553. I’m going to work on it and will make a pull request.

The guest is me (I forgot to log in before publishing)


So here is the pull request #200
Hope it will be taken into account soon for the 3.0.8 release



Thanks for the pull request, I merged it in so it will be pat of 3.0.8