I tried to add a couple of new columns with one column as a foreign key to another table and it didn�t create the FK constraint. Am I doing something wrong or is this a bug?
Rick Cromer
Here�s the XML for the change set.
When I run updateSQL or update the creation of the foreign key is not made. Here�s the updateSQL output below:
– Ran at: 5/22/09 10:50 AM
– Against: POST3@jdbc:oracle:thin:@loghost:1521:ENTICE
– LiquiBase version: 1.9.1
– *********************************************************************
SELECT COUNT(*) FROM DATABASECHANGELOGLOCK WHERE ID=1;
– Changeset post3Schema.xml::182::cruml::(MD5Sum: fedff0f6941fcc8c1866949687d3fb43)
– Add new columns to the DID_LOT table
ALTER TABLE DID_LOT ADD VENDOR_ID NUMBER(10);
ALTER TABLE DID_LOT ADD LOAD_DATE DATE DEFAULT SYSDATE NOT NULL;
INSERT INTO DATABASECHANGELOG (DATEEXECUTED, AUTHOR, LIQUIBASE, DESCRIPTION, COMMENTS, MD5SUM, ID, FILENAME) VALUES (SYSDATE, ‘cruml’, ‘1.9.1’, ‘Add Column’, ‘Add new columns to the DID_LOT table’, ‘fedff0f6941fcc8c1866949687d3fb43’, ‘182’, ‘post3Schema.xml’);
– Release Database Lock
UPDATE DATABASECHANGELOGLOCK SET LOCKEDBY = NULL, LOCKGRANTED = NULL, LOCKED = 0 WHERE ID = 1;