DB2 CLP - The tsql of DB2

Problem

How to use the DB2 CLP ( command Line processor ) to debug connections to a DB2 database.

Check that the iQSonar can really access the DB2 DB,  execute the commands required and return the expected results.

Solution

 

 From "WIndows Start" select IBM DB2 DB2COPY -> DB2 Command Line Processor

This package must be downloaded and installed by the client and is required for iQSonar to make connection to the Target DB2 Databases

  • Run the program.

You will see a Command window open

 Commands needed to access DB -------------------------------------

  • list node directory
  • catalog tcpip node SAMPLE remote 192.168.4.119 server 50000
  • list node directory
  • attach to SAMPLE user Administrator
  • Catalog Database SAMPLE at node SAMPLE
  • list db directory
  • connect to SAMPLE user Administrator
  • SELECT INST_NAME FROM SYSIBMADM.ENV_INST_INFO
  • SELECT HOST_NAME from SYSIBMADM.ENV_SYS_INFO
  • SELECT installed_prod, installed_prod_fullname, license_installed, prod_release, license_type FROM sysibmadm.env_prod_info
  • SELECT os_name, os_version, os_release, host_name, total_cpus, configured_cpus, total_memory FROM sysibmadm.env_sys_info
  • SELECT DISTINCT grantee FROM syscat.tabauth
  • SELECT HOST_NAME from SYSIBMADM.ENV_SYS_INFO
  • SELECT INSTALLED_PROD_FULLNAME FROM SYSIBMADM.ENV_PROD_INFO
  • SELECT SERVICE_LEVEL FROM SYSIBMADM.ENV_INST_INFO
  • disconnect SAMPLE
  • uncatalog node SAMPLE

OTher Catalogs ---------------------------------

  • catalog tcpip node dougal remote 192.168.4.119 server 50000 catalog tcpip node SAMPLE remote 192.168.4.119 server 50000 catalog tcpip node ted remote 192.168.4.119 server 50000

Filter by label

There are no items with the selected labels at this time.