问题
I try to integrate a versioning system for my databases. I use liquibase.
I work with the diff system because I modify the sql directly and I don't want to have to report the changes I made manually.
It works for schemas but not really for datas. I tried to use the difftype=data
on generatechangelog
but I don't know how to do to compare 2 databases datas.
Do you have any solution ?
回答1:
If you are comparing databses you want to use diffChangeLog rather than generateChangeLog. GenerateChangeLog outputs the full creation logic for a single database, it doesn't compare two databases.
GenerateChangeLog supports the diffType=data attribute which will output the contents of a database as csv or insert statements, but there is no support for comparing data in two databases.
来源:https://stackoverflow.com/questions/19292945/compare-data-between-databases-with-difftype-data-liquibase