updateSQL creates duplicate DATABASECHANGELOGLOCK tables

Description

Calling liquibase.integration.commandline.Main.updateSQL to dump the DDL for an H2 database now generates duplicate entries for creating the DATABASECHANGELOGLOCK table. This works fine in 3.2.2 and broke in 3.3.0. The relevant lines from the generated DDL are:

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 -- ********************************************************************* -- Update Database Script -- ********************************************************************* -- Change Log: ... -- Ran at: 11/15/14 10:49 AM -- Against: ... -- Liquibase version: 3.3.0 -- ********************************************************************* -- Create Database Lock Table CREATE TABLE PUBLIC.DATABASECHANGELOGLOCK (ID INT NOT NULL, LOCKED BOOLEAN NOT NULL, LOCKGRANTED TIMESTAMP, LOCKEDBY VARCHAR(255), CONSTRAINT PK_DATABASECHANGELOGLOCK PRIMARY KEY (ID)); -- Initialize Database Lock Table DELETE FROM PUBLIC.DATABASECHANGELOGLOCK; INSERT INTO PUBLIC.DATABASECHANGELOGLOCK (ID, LOCKED) VALUES (1, FALSE); -- Lock Database -- Create Database Change Log Table CREATE TABLE PUBLIC.DATABASECHANGELOG (ID VARCHAR(255) NOT NULL, AUTHOR VARCHAR(255) NOT NULL, FILENAME VARCHAR(255) NOT NULL, DATEEXECUTED TIMESTAMP NOT NULL, ORDEREXECUTED INT NOT NULL, EXECTYPE VARCHAR(10) NOT NULL, MD5SUM VARCHAR(35), DESCRIPTION VARCHAR(255), COMMENTS VARCHAR(255), TAG VARCHAR(255), LIQUIBASE VARCHAR(20)); -- Create Database Lock Table CREATE TABLE PUBLIC.DATABASECHANGELOGLOCK (ID INT NOT NULL, LOCKED BOOLEAN NOT NULL, LOCKGRANTED TIMESTAMP, LOCKEDBY VARCHAR(255), CONSTRAINT PK_DATABASECHANGELOGLOCK PRIMARY KEY (ID)); -- Initialize Database Lock Table DELETE FROM PUBLIC.DATABASECHANGELOGLOCK; INSERT INTO PUBLIC.DATABASECHANGELOGLOCK (ID, LOCKED) VALUES (1, FALSE);

Environment

  • H2 embedded database

  • Centos 6.5

Status

Assignee

Unassigned

Reporter

Baron Roberts

Labels

None

Components

Fix versions

Affects versions

3.3.0

Priority

Blocker