Command Properties File

You can optimize command lines by storing command line arguments in a command properties file (.properties), then use the /CP: parameter in the command line to refer to that file when you execute the Outline Load utility. For example, you can use a command properties file to run the same commands on multiple applications. You would only need to change the /A parameter in the command line for each import.

Reasons to consider using a command properties file:

  • Command lines are shorter and easier to manage

  • Readability

  • Ease of use

  • You can bundle switches for a common application

The Java .properties file contains entries that are key-value pairs. The key value pairs are separated with a colon (:) or an equals sign (=); for example:

  • Key:value or /I:c:/tmp/anInputCSVTextFile.txt

  • Key=value or /cp= c:/tmp/anInputCSVTextFile.txt

Entries in the properties file are used as command switches for the utility. For arguments that appear in both the properties file and in the command line, command line arguments take precedence. The command line and properties file switches are merged at runtime and the results of the parsing are displayed in the log.

For example, the following command line:

 /A:tr2 /U:admin /M /K /8 /DF:mm-dd-yyyy /I:c:/tmp/loadAccounts.csv /D:Account /CP:c:/tmp/myProps.properties

And the myProps.properties file containing the following arguments:

/DF:yyyy-mm-dd
/D:Entity
/T

Would output these log messages showing the result of the parsing:

  • Properties file arguments: /DF:yyyy-mm-dd /D:Entity /T

  • Command line arguments: /A:tr2 /U:admin /M /K /8 /DF:mm-dd-yyyy /I:c:/tmp/loadAccounts.csv /D:Account /CP:c:/tmp/myProps.properties

  • Submitted (merged) command line: /A:tr2 /U:admin /M /K /T /8 */DF:mm-dd-yyyy /I:c:/tmp/loadAccounts.csv */D:Account /CP:c:/tmp/myProps.properties

Note:

An asterisk denotes that the command switch was found in both the properties file and in the command line and that the command line version has superseded the command property file version.