DISPLAY PLAN or TRAN

The output of the DSNC DISPLAY PLAN or DSNC DISPLAY TRANSACTION command includes the name of the DB2ENTRY, *POOL, or *COMMAND for which each thread has been created.

Figure 1 shows an example of the output for the DSNC DISPLAY (PLAN or TRANSACTION) command. For each created thread the output shows the name of the DB2ENTRY or '*POOL' for the pool, or the '*COMMAND' for which it has been created.
Figure 1. Sample output from DSNC DISPLAY (PLAN or TRANSACTION) command
 
DFHDB2013 07/09/98 15:26:47 IYK4Z2G1 Display report follows for threads
accessing DB2 DB3A
DB2ENTRY S PLAN     PRI-AUTH SEC-AUTH CORRELATION  TRAN TASK  UOW-ID
*POOL    A TESTC05  JTILLI1           POOLXC050001 XC05 01208 AEEEC0321ACDCE00
XC06     * TESTC06  JTILLI1           ENTRXC060003 XC06 01215 AEEEC0432F8EFE01
XP05     A TESTP05  JTILLI1           ENTRXP050002 XP05 01209 AEEEC03835230C00
XP05     I TESTP05  JTILLI1           ENTRXP050004
DFHDB2020 07/09/98 15:26:47 IYK4Z2G1 The display command is complete.
 
The column named 'S' denotes the status of the thread, and can take the following values:
*
The thread is active within a unit of work, and is currently executing in DB2.
A
The thread is active within a unit of work, but is not currently executing in DB2.
I
The thread is inactive; it is a protected thread that is waiting for new work.

The PLAN associated with the thread is displayed (there is no plan for command threads).

The PRI-AUTH field shows the primary authorization ID used for the thread. The SEC-AUTH field shows the secondary authorization ID (if any) for the thread.

The CORRELATION fields shows the 12-byte thread correlation ID which is made up as eeeettttnnnn where eeee is either COMD, POOL or ENTR indicating whether it is a command, pool or DB2ENTRY thread; tttt is the transid, and nnnn is a unique number.

Note: A correlation ID passed to DB2 can be changed only by the CICS Attachment Facility issuing a signon to DB2. If signon reuse occurs by a thread using a primary authorization ID which remains constant across multiple transactions (for example, by using AUTHID(name)) only one signon will occur. In this instance the tttt in the correlation ID does not match the running transaction ID. It is the ID of the transaction for which the initial signon occurred.

If the thread is active within a unit of work, the CICS transaction name, its task number and finally the CICS local unit of work ID is displayed.

The correlation ID used in this display is also output on DB2 commands such as DISPLAY LOCK. For example, by using this display in conjunction with a display locks command you can find out which CICS task is holding a lock within DB2.