DB2 Connect User's Guide

Creating a Database Object

The database object defines the host or AS/400 database server to DB2 Connect; it must always be defined. For each host or AS/400 database server that you will access, use the DCE command cdscp create object to create a database object. For example:

   cdscp create object database_global_name

Add the following attributes to the object:

DB_Object_Type
D for database

DB_Product_Name
The relational database product. For example, DB2_for_MVS, or DB2_for_OS390.

DB_Native_Database_Name
The database name on the host or AS/400 database server system, as follows:

MVS or OS/390
The LOCATION value

VSE or VM
The database name

OS/400
The relational database name

DB_Database_Protocol
DRDA

DB_Authentication
SERVER, CLIENT, or DCE, as described in Security with DCE Directory Services.

DB_Principal
If the Authentication method is DCE, enter the DCE Principal in this attribute.

DB_Communication_Protocol
The following information about the communication protocol between the DB2 Connect server and the host or AS/400 database server:

To create a Database object with system security, you could put the following instructions into a file:

   create object /.../cdscell1/subsys/database/DBMVS01
   add    object /.../cdscell1/subsys/database/DBMVS01 DB_Object_Type=D
   add    object /.../cdscell1/subsys/database/DBMVS01 DB_Product_Name=DB2_for_MVS
   add    object /.../cdscell1/subsys/database/DBMVS01 DB_Database_Protocol=DRDA
   add    object /.../cdscell1/subsys/database/DBMVS01 DB_Native_Database_Name=\
                     NEW_YORK
   add    object /.../cdscell1/subsys/database/DBMVS01 DB_Authentication=SERVER
   add    object /.../cdscell1/subsys/database/DBMVS01 DB_Communication_Protocol=\
                     APPC;SPIFNET;NYM2DB2;DB2DRDA;IBMRDB;PROGRAM

Then, enter the command:

   cdscp < filename
Note:In the file, specify a backslash (\) whenever you want a statement to continue to the next line.

To create a Database object with DCE security you could put the following instructions into a file:

   create object /.../cdscell1/subsys/database/DBMVS02
   add    object /.../cdscell1/subsys/database/DBMVS02 DB_Object_Type=D
   add    object /.../cdscell1/subsys/database/DBMVS02 DB_Product_Name=DB2_for_MVS
   add    object /.../cdscell1/subsys/database/DBMVS02 DB_Database_Protocol=DRDA
   add    object /.../cdscell1/subsys/database/DBMVS02 DB_Native_Database_Name=\
                     NEW_YORK
   add    object /.../cdscell1/subsys/database/DBMVS02 DB_Authentication=DCE
   add    object /.../cdscell1/subsys/database/DBMVS02 DB_Principal=\
                 /.../cdscell1/principal_name
   add    object /.../cdscell1/subsys/database/DBMVS02 DB_Communication_Protocol=\
                     APPC;SPIFNET;NYM2DB2;DB2DRDA;IBMRDB;NONE

Then, enter the command:

   cdscp < filename


[ Top of Page | Previous Page | Next Page ]