Empty SQL changelog file

Hi,

if i want to create a changelog file for a SQLite database (temp-changelog.sqlite.sql), the resulting file is empty. If I change the file type to JSON (temp-changelog.sqlite.json) everything works as expected.

What do I have to do, to get the SQL changelog file?

Thanks.

@aDramaQueen
Do you get any hint somewhere ?
We have the same issue. We changed our Linux system from OracleLinux 7.9 to 8.9. This also updates the GNU sed … maybe this has faced the issue ?
We are using an quite old Liquibase (3.5.3) but the upgrade is one of my next projects.
Thanks

Well…, I looked up the loggings & I’m more confused than before. Here’s a snapshot of the last lines:

NOTE 1: I am using the Liquibase Hibernate & Gradle plugins. But in the end both of them just forward to the Liquibase command line.

NOTE 2: I am running this on my German machine.

...
[2024-09-10 14:03:14] FEIN [liquibase.servicelocator] Loaded liquibase.sqlgenerator.SqlGenerator instance liquibase.sqlgenerator.core.DropDefaultValueGeneratorSnowflake
[2024-09-10 14:03:14] FEIN [liquibase.servicelocator] Loaded liquibase.sqlgenerator.SqlGenerator instance liquibase.sqlgenerator.core.DropProcedureGeneratorSnowflake
[2024-09-10 14:03:14] FEIN [liquibase.servicelocator] Loaded liquibase.sqlgenerator.SqlGenerator instance liquibase.sqlgenerator.core.InsertOrUpdateGeneratorSnowflake
[2024-09-10 14:03:14] FEIN [liquibase.servicelocator] Loaded liquibase.sqlgenerator.SqlGenerator instance liquibase.sqlgenerator.core.RenameTableGeneratorSnowflake
[2024-09-10 14:03:14] FEIN [liquibase.servicelocator] Loaded liquibase.sqlgenerator.SqlGenerator instance liquibase.sqlgenerator.core.RenameViewGeneratorSnowflake
[2024-09-10 14:03:14] FEIN [liquibase.servicelocator] Loaded liquibase.sqlgenerator.SqlGenerator instance liquibase.sqlgenerator.core.SetColumnRemarksGeneratorSnowflake
[2024-09-10 14:03:14] FEIN [liquibase.servicelocator] Loaded liquibase.sqlgenerator.SqlGenerator instance liquibase.sqlgenerator.core.SetTableRemarksGeneratorSnowflake
[2024-09-10 14:03:14] FEIN [liquibase.servicelocator] Loaded liquibase.sqlgenerator.SqlGenerator instance liquibase.sqlgenerator.core.GetViewDefinitionGeneratorSnowflake
[2024-09-10 14:03:14] WARNUNG [liquibase.command] Diff changelog command failed
[2024-09-10 14:03:14] INFORMATION [liquibase.command] Command execution complete
Liquibase command 'diff-changelog' was executed successfully.
[2024-09-10 14:03:14] INFORMATION [liquibase.ui] Liquibase command 'diff-changelog' was executed successfully.

Notice the 4 last lines:

  • Diff changelog command failed
  • Liquibase command 'diff-changelog' was executed successfully.

Liquibase is sending me some contradictory signals here…?!?

Example empty changesets can be found here:

Our problem is that the file is parsed and the source file is filled.
It works with Oracle (Redhat) Linux 7.9 but not in 8.9.
The File is empty in 8.9. Seems the GNU sed in the new version does it in a different way

@uwe I already wrote a longer more detailed answer, but it was blocked since it contained links (funny enough: to the Liquibase DOCs, therefore their own website). They wrote it will be checked & posted soon. This was round about 24h ago…

Anyway, long story short, I get confusing answers from Liquibase loggings:

  • Diff changelog command failed
  • Liquibase command ‘diff-changelog’ was executed successfully

@daryldoak I don’t understand this response? We don’t want empty files. We want the changelog files in the SQL format. But we get an empty file instead. From the logging I can see everything works. Liquibase is recognising all necessary tables. Everything but the final step (writing it to a file) works as expected.

Furthermore, if I change the target file type to anything else (JSON, YAML, XML) it works. Just the specific case in the SQL format does not work.

Sorry, the original question was vague, and I misunderstood it. There was no indication that you were trying to run diff-changelog.