Function documentationCommand File Mode Locate this document in the navigation structure

 

In command file mode, a command file written by the user is processed sequentially. The command file can contain any sequence of Loader commands and SQL statements.

Features

You can start Loader CLI in command file mode by entering the following command:

Syntax Syntax

  1. loadercli -b <command_file>
End of the code.

If you want to transfer additional information when Loader CLI is called, use the corresponding options.

Syntax Syntax

  1. loadercli -b <command_file>
      [<connect_options>]
      [<in_output_options>]
      [<version_options>]
End of the code.

Enter the name of the command file after option –b. You can also enter the requested options for establishing the connection, for input and output control and for version queries. Loader reads the Loader commands and SQL statements from the specified command_file and transfers them to the Loader server. You can also create a command file by generating the design data in transport mode.

command_file

<command_file>

Command file

connect_options

-d <database_name>

Name of database

-u [<database_user>[,<password>]]

Name and password of database user

-n <database_computer>[:<port>]

Name of database computer

-s <schema_name>

Name of schema

-e <encryption>

Encryption method

More information: Opening a Database Session: Loader CLI Options

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

More information: Input and Output: Loader CLI Options

version_options

-V

Version of Loader server

-v

Version of Loader CLI

-R <installation_path>

Directory containing the programs that are dependent on the version of the database software

More information: Determing Version Information: Loader CLI Options

Example

Example Example

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

End of the example.

Loader establishes a connection to the database DEMOB for the user MONA. 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 after 20 error messages. For more examples, see the Loader Tutorial, Command File Mode.