Hi,
I’m using Liquibase via Spring Integration.
How can I see an executed SQL for a changelog?
PS My goal is to see it in log4j, i tried adding loggers with debug verbosity but it didn’t help.
Thanks In Advance,
Vitaliy S
Hi,
I’m using Liquibase via Spring Integration.
How can I see an executed SQL for a changelog?
PS My goal is to see it in log4j, i tried adding loggers with debug verbosity but it didn’t help.
Thanks In Advance,
Vitaliy S
Okay, so here it goes:
}
This is implemented in Clj-Liquibase here:
Hope that helps.
Regards,
Shantanu
Thank you very much for reply.
I’ll what sort of programmatic access do I need?
I have a spring bean which liquibase provided, if needed I can subclass from it and perform all necessary steps, just need a hint where to dig
Regards,
Vitaliy S
By using the Liquibase API you can generate the set of SQL statements that will be executed for a given change. This, however, requires programmatic access.
Regards,
Shantanu
Hi all,
So as i came across the same problem i decided to share my solution (propably not the best).
As i’m also using the Spring integration i knew i have to ‘hook’ my code to print out the statements.
That is because the SpringLiquibase class is using the update(context) method from the Liquibase
class.
I extended the SpringLiquibase class and overwritten the afterPropertiesSet() method. Here is how:
Hope this helps,
dave00