## USE DB Command

You can use the Loader’s USE DB command for starting a database to establish a connection to another database instance.

### Syntax

<use_database_command> ::= USE DB <database_spec>

<database_spec> ::= <database_name>
[ON <database_computer> [ENCRYPTION <protocol_name>]]

<database_name> | Name of database instance Valid for the entire Loader session with this database instance If the name of the database instance is identical to a keyword or if the upper- and lowercase notation is relevant, the name must be placed in quotation marks. see: Concepts of the Database System, Conventions for Database Names
<database_computer> | Name of the computer on which the database instance is installed for which a Loader session is to be started. If this is not specified, the Loader assumes that the specified database instance was created on the computer to which the user of the Loader is logged on.
<protocol_name> | Name of the encryption protocol In addition, you can specify, after the key word ENCRYPTION, the name of the requested encryption protocol protocol_name to ensure the data transfer is encrypted. This option is currently only supported for SAP systems and SSL.

### Examples

USE USER mona red DB demodb ON genua

//

USE DB demodb ON parma

User MONA is logged on to database instance DEMODB on computer GENUA. You use the USE DB command to switch to database instance DEMODB on computer PARMA.

### Explanation

With the USE DB command, you switch to another database instance without having to exit the Loader. The connection to the current database instance is terminated and the new connection to the database instance is set up. A database user with the same name and password must exist on the new database instance. All subsequent commands are referred to this database instance by the Loader.

This setting applies as long as no other database instance is specified with a USE DB command.

See also:

Creating a Database Session: Commands

Options for Establishing a Connection