Changes made by liquibase CLI are not recognized by liquibase maven plugin, and vice-versa

That is usually called by differences in the changelog paths when you run liquibase update. The changelog name and path are stored in the databasechangelog table as part of the changeSet identifier and they need to match to be considered equal changeSets. 

If you run “select * from databasechangelog” you can see the types of values that have been saved. Make sure both methods of running liquibase use the same changelog paths.

Alternately, you can use the logicalFilepath attribute to force the path used for changeSet comparisions, regardless of the actual path they have.


I’m using liquibase with postgres on Windows 7 64 bit and got this issue: I used liquibase CLI to update my database, then after that configured liquibase maven plugin to udpate change automatically (bind the liquibase:update goal to the process-resource phase), the plugin failed to detect that the some changesets are already applied to the database though I can see the databasechangelog table has all the value for the applied changesets. Same issue when I tried to run mvn liquibase:update directly on the command line. I use version 3.0.7 for both liquibase binary and plugin, schema version 3.0 for my changelog files.

In order to avoid the issue I could choose to use maven plugin only, but it would be much more convinient to be able to use the CLI sometimes.

I was thinking of creating an extension to have Liquibase ignore the file path for people who don’t need that additional identifier. 

Where in the docs did you see it list only the id and author as the identifiers? The docs should always include the path as well.


Thank you Nathan,

I checked, the file paths are different from when I updated with CLI liquibase and mvn liquibase plugin and that’s why things were messed up. But I just think it would be nicer, more simple and straightforward if changes are indentified by changesetID and author only. And that is exactly what the documentation says.

Currenly I am using logicalFilePath as you suggested. But it would be nice if you create that extension. That would also fix my problem with formatted SQL files because from what I read, I can’t set logicalFilePath for SQL file, only XML; or can I?

This: is where I got the understanding about change’s uniqueness (go to the question about author tag), and it didn’t mention filename or file path. After checking the main documentation I realized that in there you did mentioned file path as well ( My bad I read the FAQ first and the idea stuck in my head, but the FAQ could be improved too to eliminate the confusion.

Thank you.

I’ll take a look at the faq and see what I can do. Thanks for pointing it out.

You are right that the formatted sql doesn’t support logicalFilePath. I created will let me write the extension.