I would like to create a snapshot of my Oracle database containing multiple schemas, so that I can later run a diff between the snapshot and the possibly-changed database.
I am using Liquibase Community 4.4.3 on Linux, Java 8, an Oracle 12c database, and ojdbc8.jar.
I am referencing “Diffing Multiple Schemas in Liquibase”:
- Run the
snapshotcommand to capture the state of the database containing different schemas:
liquibase --outputFile=mySnapshot.json snapshot --snapshotFormat=json --schemas=lookup,public
When running the
snapshot command on multiple schemas, enter the
--schemas flag after the
However when I try it like this:
liquibase --snapshotFormat=json --outputFile=test_snapshot.json --url=jdbc:oracle:thin:@myhostname.local:1521/dbname.local --username=liquibase --password=Password123 snapshot --schemas=SCHEMA1,SCHEMA2
It throws error:
Unexpected argument(s): --schemas=SCHEMA1,SCHEMA2
For detailed help, try ‘liquibase --help’ or ‘liquibase --help’
I am hoping to capture the definition of tables etc from both SCHEMA1 and from SCHEMA2 into file test_snapshot.json, so that I could later on use the diff command against that file and the current database (using a reference URL).
I am not using a liquibase.properties file. All parameters are passed on the command line.
Could anyone point me in the right direction please?