Data Compare for Oracle 2

Command line switches

/abortonwarnings:<warning level>

Alias: /aow

Aborts the deployment if there are any deployment warnings. You can specify none (default), medium, or high.

/activateserial:<serial number>

An internet connection is required to activate Data Compare for Oracle from the command line.

For information about how to activate manually without an internet connection, see Activating.

Attempts to activate Data Compare for Oracle.

You can specify a Data Compare for Oracle serial number, or a serial number for bundle such as the Deployment Suite for Oracle:

dco /activateSerial:123-456-789012-ABCD

If you run the switch without specifying a serial number, the Activate Data Compare for Oracle dialog box opens:


If you're using the Data Compare for Oracle command line on a server, you need a DLM Automation Suite for Oracle license.

/behavior:<value>

This switch only works if you specify values for /source and /target.

Alias: /b

Specifies options that affect deployment behavior.

The default is scriptheader.

ValueAlias
deferconstraintsf
disableconstraintsc
disabletriggerst
scriptheaderh
defineoffd
removecontrolcharactersr
useunistrinstringliteralsu
alwaysusecolumnnamesa
Behavior options can be bundled (eg /b:dt) or used in long format (eg /behavior:defineoff /behavior:disabletriggers).

Specifying a value for either /behavior or /comparison clears the defaults for both switches.

For example, if you specify /b:f, the defaults /c:wc and /b:h no longer apply.

/comparison:<value>

This switch only works if you specify values for /source and /target.

Alias: /c

Specifies options that affect comparison.

The defaults are ignorewhitespace and ignorecontrolcharacters.

ValueAlias
trimtrailingspacess

ignorewhitespace

w

ignorecontrolcharacters

c
ignoredatetypedifferencest
checkfordatad
includeviewsv
Comparison options can be bundled (eg /c:dv) or used in long format (eg /comparison:checkfordata /comparison:includeviews).

Specifying a value for either /behavior or /comparison clears the defaults for both switches.

For example, if you specify /c:s, the defaults /c:wc and /b:h no longer apply.

/comparisonkeys:<regular expression>:<index name or comma-separated columns>

This switch only works if you specify values for /source and /target.

Alias: /ck

Specifies which index or column(s) to use as the comparison key for specific tables or views (case-insensitive). If a column and an index have the same name, the index will be used.

For example, to use PK_WidgetPrices as the comparison key in the table WidgetPrices:

dco ... /comparisonkeys:"WidgetPrices":PK_WidgetPrices
dco ... /comparisonkeys:"WidgetPrices":WidgetID,Active

Specify the name of the table or view using a regular expression. We recommend you use a regular expression that matches only one table or view, by surrounding the name in double quotes. 

 More information on how to specify table and view names using regular expressions

/deactivateserial

Attempts to deactivate Data Compare for Oracle. An internet connection is required to deactivate the product.

/deploy

Alias: /d

Deploys the schemas after comparison. Changes are migrated from <schema1> to <schema2>.

/deployscriptencoding:<encoding>

Alias: /depenc

Specifies the character encoding to use when writing the deployment script file. The default is UTF8.

Arguments

UTF8UTF-8 encoding, without preamble
UTF8withpreambleUTF-8 encoding, with 3-byte preamble
UnicodeUTF-16 encoding
ASCIIASCII encoding

Example

dco /project:"C:\Data Compare for Oracle\Projects\WidgetDatabases.dco"
/scriptfile:"C:\Deployment Scripts\WidgetDeployment.sql"
/deployscriptencoding:ASCII

/direct

Forces the connection to use the internal Oracle client where possible. You can't connect via TNS name or service name using this option, but no Oracle client (eg Oracle Instant Client) is required.

/exclude:<regular expression>

This switch only works if you specify values for /source and /target.

Specifies objects to exclude (case-insensitive).

Use /exclude for each object you want to exclude. Alternatively, use /exclude only once, and specify table or view names using regular expressions. Use double quotes (") for an exact match.

For example, to include the table Contacts:

dco ... /exclude:"Contacts"
More information on how to specify table and view names using regular expressions

/exclude takes precedence over /include.

/excludecolumns:<regular expression>:<comma-separated column names>

This switch only works if you specify values for /source and /target.

Alias: /ec

Specifies columns to exclude for specific tables or views. Specify table or view names using regular expressions.

For example, to exclude the column WidgetName in the table WidgetReferences:

dco ... /excludecolumns:"WidgetReferences":WidgetName

/excludecolumns takes precedence over /includecolumns.

More information on how to specify table and view names using regular expressions

/help

Alias: /?

Display help, with a list of all commands. Use in conjunction with /verbose for more detailed information. If this switch is used with any switches other than /verbose, those switches will be ignored.

/include:<regular expression>

This switch only works if you specify values for /source and /target.

Specifies objects to include (case-insensitive).

Use /include for each object you want to include. Alternatively, use /include only once, and specify table or view names using regular expressions. Use double quotes (") for an exact match.

If you specify /include, all other tables and views are excluded by default. For example, to include only the table Products:

dco ... /include:"Products"

/exclude takes precedence over /include.

More information on how to specify table and view names using regular expressions

/includecolumns:<regular expression>:<comma-separated column names>

This switch only works if you specify values for /source and /target.

 Alias: /ic

Specifies columns to include for specific tables or views. Specify table or view names using regular expressions.

 If you specify /includecolumns, all other columns are excluded by default.

For example, to include only the columns ID, Price, and Date in the table WidgetPrices:

dco ... /includecolumns:"WidgetPrices":ID,Price,Date

More information on how to specify table and view names using regular expressions

/includerows:<value>

This switch only works if you specify /deploy, /report, or /scriptfile.

You can't specify /deploy or /scriptfile with /includerows:identical.

Alias: /ir

Specifies types of rows to include in reports, scripts, or deployments. Specify multiple values as a comma-separated list. The defaults are source, target, and different.

Example

dco ... /includerows:source,different
identical

Rows that are in both source and target, where all columns are equal. Unaffected by deployment.

source

Rows that are only in the source. Generates INSERT statements.

target

Rows that are only in the target. Generates DELETE statements.

different

Rows that are in both source and target as matched by the comparison key but other columns are modified. Generates UPDATE statements.

/indirect

Forces the connection to use the installed Oracle client (eg Oracle Instant Client), so you can connect using a service name (default).

/loglevel:<level>

Alias: /log

Creates a log file with a specified minimum log level. The default is none.

Log files collect information about the application while you're using it. These files are useful to us if you've encountered a problem. For more information, see Logging and log files.

Arguments

None

Disables logging

Error

Reports serious and fatal errors

Warning

Reports warning and error messages

Verbose

Reports all messages in the log file

Example

dco ... /loglevel:verbose
You must use /loglevel each time you want a log file to be created.

/onlyfirst1000rows

Alias: /1000

Shows only the first 1000 rows in the report.

/overwritereports

Alias: /f

Forces the overwriting of any report files that already exist. If this switch isn't used and a file of the same name already exists, the program will exit with the exit code indicating an IO error.

/project:<project file>

Alias: /p

Specifies a saved Data Compare for Oracle project file (.dco) to compare.

dco /project:"C:\Data Compare for Oracle\Projects\WidgetDatabases.dco"

/quiet

Alias: /q

Quiet mode - displays no output.

/report:<file name or directory>

Alias: /r

Exports results as .csv files to the specified directory, or as an HTML report to the specified file name. If the /reporttype is CSV, this specifies a directory to export the .csv files to. If the /reporttype is HTML, this specifies a file name to write the HTML report to.

To overwrite an existing report file, use /overwritereports. If you try to export a report file with the same name as an existing report file without using /overwritereports, the program will exit with the exit code indicating an IO error.

/reportrows:<reportrows1>:<reportrows2>:...<reportrowsN>

This switch is deprecated. Instead use /includerows.

/reporttype:<report type>

Alias: /rt

Values: CSV (default), HTML

Specifies the type of report produced by the /report switch.

/scriptfile:<file name>

Alias: /sf

Generates a SQL deployment script which can be executed at a later time.

/source:<value>

 Alias: /s

The data source and schema(s) to use as the comparison source. The schemas are compared in the order they appear.

Live without Oracle client:

user/pass@host[:port]/sid{SchemaA} [AS (Normal|SYSDBA|SYSOPER)] (/direct)

Live with Oracle client:

  • TNS name:
(user/pass|/)@tns{SchemaA, SchemaB} [AS (Normal|SYSDBA|SYSOPER)]
  • Manual connection:
(user/pass|/)@host[:port]/service{SchemaA, SchemaB} [AS ...] (/indirect)
  • LDAP
(user/pass|/)@ldap{SchemaA, SchemaB} [AS ...]

/target:<value>

Alias: /t

The data source and schema(s) to use as the comparison target. The schemas are compared in the order they appear.

Live without Oracle client:

user/pass@host[:port]/sid{SchemaA} [AS (Normal|SYSDBA|SYSOPER)]

Live with Oracle client:

  • TNS name:
(user/pass|/)@tns{SchemaA, SchemaB} [AS (Normal|SYSDBA|SYSOPER)]
  • Manual connection:
(user/pass|/)@host[:port]/service{SchemaA, SchemaB} [AS ...] (/indirect)
  • LDAP
(user/pass|/)@ldap{SchemaA, SchemaB} [AS ...]

/verbose

Alias: /v

Verbose mode - displays detailed output.

Contents


Didn't find what you were looking for?