Function documentationInput and Output: Loader CLI Options Locate this document in the navigation structure

 

In Command File Mode and Session Mode you can specify Loader CLI options for defining version information.

in_output_options

-o[w|a] <file_name>

Name of output file

-cs <separator>

Command separator

-ps<number> <string>

Substitution parameter

-E <number>

Maximum number of errors allowed

-o[w|a] <file_name>

If you are working in command file mode, this option enables you to ensure that Loader output is written to the specified file file_name. In session mode, Loader does not evaluate this option. Default: if you do not specify the option, Loader outputs to the screen.

  • Option -ow <file_name>: The file is opened for writing and any existing entries are deleted.

  • Option -oa <file_name>: The file is opened for writing and output is appended to the end of the file without any previous entries being deleted.

Note Note

This option refers to output from Loader only . Loader also writes a log file.

End of the note.
-cs <command_separator>

With this option you can define which characters of Loader CLI should be recognized as command separator. A command separator completes a Loader command, which can then be processed by Loader. A command separator must contain at least one and no more than two characters.

  • Command file mode: Default: Individual commands end with a line, preceded by two forward slashes //. If you specify a command separator with the –cs option, the command ends with this command separator (see also: Command File).

  • Session mode: Default: Commands end when you press ENTEREnter a simple slash (/) at the end of the line to continue a command on the next line. If you specify a command separator with the –cs option, the command ends with this command separator. Press ENTER at the end of the line to continue a command on the next line (see also: Session Mode).

Example Example

loadercli -b command.dat -d demodb -u mona,red –cs ;

End of the example.

You call Loader CLI in command file mode using ; as command separator.

-ps<number> <string>

You use this option to specify values for placeholders in the command file. Value number defines the numbers of the placeholder to be substituted in the command file (1<=n<=9). You use string to specify the value the placeholder is to replace. This value can be any string. You can specify nine different parameters (and placeholders) for each command file. In the command file, enter the placeholder in the form &<number>.

Example Example

loadercli –b command.dat –d demodb –u mona,red –ps1 HOTEL

End of the example.

You call Loader CLI in command file mode. The system replaces the placeholders that have the form &1 with the string HOTEL in command file command.dat.

-E <number>

You use this option to specify how many (number) commands with errors should be allowed before Loader stops processing the command file.

Example Example

loadercli -b command.dat -d demodb -u mona,red –E 20

End of the example.

You call Loader CLI in command file mode. Loader processes the Loader commands and SQL statements contained in the command file command.dat. If errors occur (return code <> 0), processing of the command file is terminated when 20 commands have been terminated with an error.

Example

Loader Tutorial, Command File Mode, Session Mode