I’m currently running a Jenkins Pipeline to run Liquibase updates specified in SQL format. After running the initial update, which consists of 39 changelog files, which each create schemas and tables/views in each, all entries are added into the DATABASECHANGELOG table correctly.
However, whenever I re-run my Jenkins Pipeline to run an update with additional changesets added to 2 of the changelogs, Liquibase creates new records in DATABASECHANGELOG table for every single changeset. Not just the 15 new ones, but also the 1556 ones that were already in place.
For example, one changeset already in place.
SELECT * FROM DATABASECHANGELOG WHERE ID = ‘4_102’;
What is causing this? Shouldn’t the author and ID uniquely identify each changeset?
FYI this is the specific changeset from the SQL changelog file.
create or replace TABLE BENE_PTA_PRM_RATE_RDCTN_CD (
BENE_PTA_PRM_RATE_RDCTN_CD VARCHAR(1) NOT NULL,
META_SK NUMBER(38,0) NOT NULL DEFAULT 0,
META_SRC_SK NUMBER(38,0) NOT NULL DEFAULT 0,
constraint PK_BENE_PTA_PRM_RATE_RDCTN_CD primary key (BENE_PTA_PRM_RATE_RDCTN_CD) rely
Any ideas for troubleshooting this will be helpful. I’ve already removed the DATABASECHANGELOG AND DATABASECHANGELOGLOCK tables, and dropped all schemas managed by Liquibase, and had Liquibase re-create them upon the initial update.