Page History
Div | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||
|
There are two options to configure the DB2 client:
- via the connection string, which corresponds to the setting DBName in the E2E Bridge BRIDGE ...
- ... or on each client using the catalog database commands .
...
Install the DB2 drivers on your client system (IBM Data Server Driver for ODBC and CLI (CLI Driver). In the xUML Services Preferences of the Bridge, select the DB2 adapter preferences and enter the installation directory of the driver as DB2DIR.
The value of DB2INSTANCE is not used in this case.
Specify the DB2 server in the xUML Service Settings of the SQL adapter connection of the xUML service. All possible parameters are documented on the IBM documentation pages.
For more information on xUML service settings refer to xUML Service Settings.
Alternatively, you can also specify the DB2 server in the <<SQLAlias>> in the component diagram of the xUML service.
For more information on the SQL database deployment refer to section ODBC in the E2E Bridge the BRIDGE Reference Guide.
Configuring DB2 Access via the SQL Client
...
Example: db2 => catalog tcpip node DBSERVER remote dbserver1.e2e.ch server 50000
The DB2 node name DBSERVER holds the TCPIP entries for the system database directory.
DB2 Commands
Command | Description | Example |
---|---|---|
catalog tcpip node | Adds a Transmission Control Protocol/Internet Protocol (TCP/IP) node entry to the node directory. | db2 => catalog tcpip node DBSERVER remote dbserver1.e2e.ch server 50000 |
list node directory | Lists the contents of the system database directory. If a path is specified, the contents of the local database directory are listed. | db2 => list node directory Number of entries in the directory = 1 Node 1 entry: Node name = DBSERVER Comment = Directory entry type = LOCAL Protocol = TCPIP Hostname = dbserver1.e2e.ch Service name = 50000 |
uncatalog node | Deletes an entry from the node directory. | db2 => uncatalog node DBSERVER |
4. Store the Database Location Information in the System Database Directory
...
Example: db2 => catalog database SAMPLE as SAMPLE at node DBSERVER
DB2 Commands
Command | Description | Example |
---|---|---|
list database directory | Lists the contents of the system database directory. | db2 => list database directory Database 1 entry: Database alias = SAMPLE Database name = SAMPLE Node name = DBSERVER Database release level = a.00 Comment = Directory entry type = Remote Catalog database partition number = -1 Alternate server hostname = Alternate server port number = Database 2 entry: Database alias = E2E Database name = E2E Node name = DBSERVER Database release level = a.00 Comment = Directory entry type = Remote Catalog database partition number = -1 Alternate server hostname = Alternate server port number = |
uncatalog database | Deletes a database entry from the system database directory. | db2 => uncatalog database tsp The UNCATALOG DATABASE command completed successfully. DB21056W Directory changes may not be effective until the directory cache is refreshed. |
Defining the DB2 Database Preferences on the
...
BRIDGE
Multiexcerpt | ||
---|---|---|
| ||
In a browser, open the Web-based user interface of the system, on which the Bridge is installed (see Checking the Installation). Enter a user id and password of a user with administration rights (the pre-defined user admin, for instance). In the Navigation, select the xUML Services item of the node instance you want to define the database preferences for and switch to tab Preferences. Now, you can define the SQL adapter preferences for each database type. Select the DB2, Oracle, MySQL, or MSSQLServer Adapter in the drop down box and the parameters of the selected adapter are displayed. |
Select the DB2 adapter, enter the following parameters and click Apply.
Key | Value | Example |
---|---|---|
DB2DIR | Path of the DB2 SQL Library (installed with the DB2 client tool), e.g. D:\SQLLIB. |
DB2INSTANCE | Name of the SQL service component that has to be used in the deployment diagram when defining a DB2 database backend, e.g. DB2. The DB2INSTANCE environment variable can be retrieved with the DB2 administration command shell (see sections before). Use the get instance command, which returns the value of environment variable. | db2 => get instance The current database manager instance is: DB2 |
Note | icon | false
---|
Tip |
Using Windows, you do not have to set the parameter DB2DIR, if the path is already defined in the Windows PATH environment variable. |