Automatically insert into table on Liquibase Update

Hi,
we are trying to switch to Liquibase in our company. We found that logging of the statements with Liquibase is possible and it works. Now we would like to know, if there is a way, to automatically insert the executed SQL statements in a DB Table? Normally, with our old System we logged the DDL statements, therefore the question. But i didn’t found anything about such a possibility.
Thanks!

With the right logging level (sql-log-level=INFO) Liquibase will provide every executed SQL statement in the output. We take that output and insert it into a table for history.

Thank you daryldoak. How do you take that output? Did you write an own program that reads that log file? Or is there a way to let this do liquibase automatically?

We wrote our own program.

Another option would be to use the update-sql command, which shows all the SQL that will be executed. That could be inserted without needing to strip the logging.

1 Like

Thank you all for your help.