Data Compare Command Line
Last updated
Last updated
Before Using the Command line, the user needs to go to the Data Compare and create a profile that can be used as a project/profile to interact with the Command line.
Follow the following links to set up a Data compare profile.
Once the profile is completed use the given Command lines to interact with Data compare Profiles
This command compares data (as configured) within the Profile named <projectname> and applies various specified options to tailor the comparison process and its outputs.
This command will help to get the list of all profiles that are created for data compare
Terms defined in Command and their meanings
‘-project=<projectname>’: Specifies the profile containing the database configurations to be compared.
‘-download=<true|false>’: Controls whether to download the comparison reports as files. If ‘true,’ reports selected in the ‘-show’ option will save to the specified output directory; otherwise, a summary is displayed.
‘-show=<Filters>’: Comma-separated filter name(s) determines what to show in the output. Options include ‘all[default]’, ‘onlyInTarget’, ‘onlyInSource’, and ‘different’.
‘-list’: Displays a list of existing projects configured for comparison.
This command will help to get the “compare” result of the selected profile, which you get in the above step
Depending on the Use one can define the properties for Download - If ‘true,’ reports selected in the ‘-show’ option will save to the specified output directory; otherwise, a summary is displayed.
For Show one can select all three option or even one or two depending on what report they want to see either they want to know "onlysource" count "onlydestination" count or "all" counts
dbsync-cli.bat dbs compare -project=<project name> -download=false -show="OnlyInTarget, OnlyInSource, all"
Example
Note- As Download is false, this command will only show the results, but the result files will not be downloaded
While processing, it will show the job run's status, date, and completion time.
dbsync-cli.bat dbs compare -project=<project name> -download=true -show="OnlyInTarget, OnlyInSource, all"
Note- As Download is true, this command will only show the results, and also the result files will be downloaded
Example