Getting the right level of detail in your trace output
You can trace all QMF functions in detail or trace individual QMF functions.
To trace all QMF functions at the most detailed level, use a value of ALL in the TRACE column of the Q.PROFILES table. If the results of this option are too large, you can limit the amount of trace output to a specific size by setting the DSQEC_TRACE_LIMIT global variable.
- The value 1 traces a function at a medium level of detail.
- The value 2 traces a function at the highest level of detail.
|Trace ID||QMF function that is traced|
|A||Application support services|
|C||Common services and systems interface|
|D||Dialog command processing|
|E||Display services for parts of QMF such as Prompted Query, QBE, Table Editor, global variable lists, and database object lists|
|G||QBE, Prompted Query, and Table Editor full-screen windows|
|L||Message and command logging|
|P||Charting (Interactive Chart Utility)|
|R||Storage management functions|
|U||User exits, such as user edit exit routines or a governor exit routine|
SET PROFILE (T=L2A1C2
The value of the TRACE option in the QMF profile is ignored when you start QMF as
a Db2® for z/OS® stored
procedure. However, you can include a
SET PROFILE (TRACE command
in the initial procedure specified by the object-name parameter
to change the level of trace detail for the duration of the stored
procedure session as long as the L2-destination parameter
is set to DSQDEBUG. When you issue a SET PROFILE command to change
the trace settings, ensure that L2 is among the options specified
SET PROFILE (TRACE command in the initial
procedure if you want to continue tracing messages and commands.
Use the L1 and L2 trace records to precisely record user activities during a QMF session. A value of L1 writes records for all messages that are issued by QMF. L2 writes all the L1 records plus more records that describe the execution of QMF commands. Use the L2 trace code to log each command that a user issued and how QMF responded to that command. The following example of a RUN QUERY command fail because the user names columns that are not in the table.
Within the DSQDEBUG data set, the messages appear chronologically. When commands are included, they also appear chronologically and are intermixed with the messages. A message is associated with the command that precedes it in the data set or file.
QMF messages have variables for parts of the message that change, such as a table or column name. You can use the trace data to help a user decipher a message that includes variables. For example, the message that is shown in the previous example appears in QMF Messages and Codes as: Column &V1 is not in table &V2. The bottom half of the example shows that the value for &V1 in the message is DATE and that the value for &V2 is STAFF. Substitute these values into the message to help a user solve the problem.
These variables might also appear in the definition of the help panels that are associated with the error message. Use the variable values from the trace data together with the HELP command to reconstruct the message help panel if necessary.