DB2 UDB Option for CICS support

The DB2 UDB Option for CICS provides the AMD2 transaction, which automatically processes client SQL language requests using the DB2 dynamic SQL facilities.

Using this product, client applications can communicate directly with the DirectConnect for z/OS Option or with another server that communicates with DirectConnect for z/OS Option, such as ASE or ASE/CIS (as shown in Figure 8-2):

Figure 8-2: DB2 UDB Option for CICS and DirectConnect for z/OS Option support components


Tracing

The DB2 UDB Option for CICS has a trace flag that will write out MFC trace points to a CICS Temp Storage Queue, the name of which consists of the two characters “CE” concatenated to the user ID. For example, if the user name were SYBASE, the CICS Temp Storage Queue name would be CESYBASE.

For the DB2 UDB Option for CICS, you can also use the standard DirectConnect for z/OS Option tracing support. See Figure 8-1.


Logging

You can determine the errors logged. Enter changes in SOURCE library member AMD2CAMX, as detailed in the DB2 UDB Option for CICS installation instructions. For example, to indicate that you want a message logged, set LOG=Y.

SYRTMAMX TYPE=ENTRY, MSGNR=32000, SQLCODE=0, LEVEL=11, STATEC=0, STATESC=0, LOG=Y, SQLFATAL=N

WARNING! If a connection fails, the error log is the only method of tracking an error. To prevent the log from running out of room, initialize the log file regularly.

In a CICS environment, the DB2 UDB Option for CICS provides the AMD2LOG and AMD2LOGO files. The AMD2 transaction writes errors to AMD2LOG, including task ID, term ID, timestamp, and the unique message code for each error. AMD2 also returns an error message to the client.

Under CICS, if AMD2LOG is full or no longer accepts messages, AMD2 writes errors to the overflow file, AMD2LOGO. AMD2 then issues error message 33219:

MainframeConnect for DB2 UDB error (Write to log file AMD2LOG failed, switching to overflow log AMD2LOGO).

Under CICS, you can close, archive (if desired), and purge AMD2LOG when it becomes full. During the time AMD2LOG is closed, AMD2 writes messages to AMD2LOGO that you can close, archive, and purge once you reopen AMD2LOG.

In this example, AMD2 writes an internal error 32000 to AMD2LOG (or AMD2LOGO, if AMD2LOG is full).

For CICS environments, you must define the error log files to CICS in an FCT entry as shown: