The DB2 Data Adapter supports IBM's Distributed Relational Database Architecture (DRDA), including:
|
In this section: How to: |
Users can change their default database server with the CONNECT command.
In addition, CONNECT authority controls access to the DB2 for VM RDBMS. The administrator (or authorized person) may establish one ID and password for a group of users. Assigning CONNECT authority to the group ID, rather than the individual users, simplifies the task of administering privileges (see Connection, Authentication, and Security).
The syntax of the CONNECT command is
SQL [sqlengine] CONNECT [TO dbname|RESET]
where:
You can include the CONNECT command in a FOCEXEC such as the PROFILE FOCEXEC. The FOCEXEC may be encrypted to prevent unauthorized viewing of the DB2 for VM authorization ID and password.
Note: For DB2:
Level 2 DRDA commands include:
The syntax for the SET CONNECTION and RELEASE commands is
SQL [DB2] SET CONNECTION server_name
SQL [DB2] RELEASE {server_name|option}
where:
CURRENT
ALL [SQL]
ALL PRIVATE
Note: Omit the DB2 target RDBMS qualifier if you previously issued the SET SQLENGINE command for DB2.
You can use the SET CURRENT PACKAGESET command to switch application packages during a session. The effect is similar to the SET PLAN command, but does not require that the DB2 thread be closed and reopened (for example, when switching isolation levels).
SQL [DB2] SET CURRENT PACKAGESET {packageset_name|USER}
where:
Use of DRDA and the SET CURRENT PACKAGESET command requires that the data adapter be installed using the DB2 BIND PACKAGE command. For more information, consult with the DBA at your site or refer to the IBM DB2 Application Programming and SQL Guide.
For a complete description of these commands, refer to the IBM DB2 SQL Reference.
Information Builders |