Liquibase SQLCL relative path error

Hi there,

I really need some help, as I’ve exhausted all of the pages I can find on Google.

We’ve recently switched to using Liquibase for our production releases, and have had some pretty decent success. We’re now looking at how we perform interim releases, or hot fixes, and I’m trying to use the “context” tag in my master changelog to distinguish the changelog files for major and interim releases.

With SQLCl 19.4, it seems to completely ignore the context passed to the liquibase update command. This version of SQLCl has liquibase 3.8.1 baked into it. If I run my liquibase update command:

lb update master.xml context “”

It runs everything, regardless of what I’ve set the context tag too. And when I check the DATABASECHANGELOG table, the CONTEXTS column is null, which seems to confirm my theory.

If I upgrade SQLCl to version 20.4, and run the command:

lb update -changelog master.xml -context “”

It does seem to only run the correct context, but then throws the error “Specifying files by absolute path was removed in Liquibase 4.0. Please use a relative path or add ‘/’ to the classpath parameter”.

How do I get around this? I’m not aware of a classpath file as I’m using the SQLCl liquibase integration. I have not installed Liquibase locally, as all of our devs already have SQLCl, so it’s the better option for us. But only if I can get it to work.

Any advice would be greatly appreciated, as I am still relatively new to Liquibase, and really want to be able to use it more widely,



Hi @leeweb79

Did you miss the - before context like this: -context. Or is it just a typo? :slight_smile:

What if you run without providing context attribute. Does it work that way?

Rakhi Agrawal

Hi Rakhi. Thanks for your reply. I’ve tried both of your suggestions, but it still thinks we don’t have relative paths, although I can’t see why.

This looks like a problem we have with our implementation. Even if we run the liquibase.jar, we get the same problem, so we’ve gone back to the drawing board with our changelogs. Must be something we’re doing incorrectly, because it works with 3.8.1. We’ll persevere for now, but any further suggestions would be much appreciated.

If I do work it out, I’ll be sure to post here what we did to resolve, so others can benefit from our experience :wink:

1 Like

Hi! I guess I’ve bumped into kinda the same issue. I’ve posted it on Stackoverflow here and here. The second one is the most interesting because it’s just the case that taken from oracle-base and I can’t make it work under Windows.

The interesting part that I decided to try to run it from Ubuntu Linux Subsystem (WLS 2.0) and it worked! Looks like Windows cannot handle working directory properly. You can find my investigations in the first hyperlink. I’ve put details with paths.

1 Like

HI @krow7

Thanks for sharing your findings. This would definitely help our community members!

Rakhi Agrawal