SQL Statement and Program window

Use the SQL Statement and Package window to view information about the current SQL statement being executed or the last SQL statement that was executed by the thread.

To display this window, select SQL Statement from the Thread Detail panel. One of two possible windows is displayed depending on whether the thread is using a package or a DBRM. Only the SQL Statement and Package window is shown here in this section.

Some fields can have values that are longer than the space available to show them in this panel. When this happens, the last character in the field is replaced with an asterisk (*) to indicate that the reported value is truncated.

Figure 1. SQL Statement and Program window
 DGOMTWCS               SQL Statement and Program

                                                           More:     +
 _ SQL Statement : SELECT * FROM SYSIBM.SYSTABLES WHERE CREATOR='POD'

 Location . . . . . . . . . . . . . : PMO1D711
 Collection ID  . . . . . . . . . . : DSNESPCS
 Program name . . . . . . . . . . . : DSNESM68
 Nested activity name . . . . . . . : N/P
 Program type . . . . . . . . . . . : Package
 Consistency token  . . . . . . . . : X'149EEA901A79FE48'
 Version
 N/P
 Statement type . . . . . . . . . . : CLOSE
 Statement number . . . . . . . . . : 0
 Current SQL ID . . . . . . . . . . : POD
 Bind type  . . . . . . . . . . . . : Dynamic
 Cached dynamic SQL identifier  . . : N/A
 Thread status  . . . . . . . . . . : In DB2
 Database name  . . . . . . . . . . : N/P
 Page set name  . . . . . . . . . . : N/P
 Page number  . . . . . . . . . . . : N/P
 Elapsed time . . . . . . . . . . . : N/P
 CPU time . . . . . . . . . . . . . : N/P
 _ Used Buffer Pools
   Getpages         . . . . . . . . . : N/P
   Synch read I/O . . . . . . . . . . : N/P

 Command ===> ________________________________________________________
  F1=Help       F2=Split      F3=Exit       F5=Auto       F6=History
  F7=Up         F8=Down       F9=Swap      F12=Cancel    F16=Look
 F17=Collect   F18=Explain   F22=Purge

DB2® trace class 9 must be active to show information for the following fields:

  • Database name
  • Page set name
  • Page number
  • Elapsed time
  • CPU time
  • Getpages
  • Synch Read I/O

If class 9 is not active N/P is shown.

Use the selection fields to view the complete SQL statement text or information about the buffer pools used during the execution of the query.