Sampling for DB2 is the same as sampling for any other target. At specified intervals, data is collected about the target. The more samples collected from the same location within the target, the better areas that might have tuning opportunities are identified. For DB2, the area within the target is identified by a DB2 SQL statement. The more samples that are taken during the execution of a SQL statement, the higher the probability that a tuning opportunity exists.
The principle drawback for sampling DB2 is that DB2 reuses structures. When a sample is taken there is a chance that the data in the object being sampled is left over from a previous call to DB2. CA Mainframe Application Tuner uses a number of techniques to resolve any discrepancies, but they will occur, especially when collecting the source of the SQL statement. The SQL statement is collected from other sources as well as sampling; therefore, CA Mainframe Application Tuner provides two commands in the TUNSSP00 member to suppress the collection of SQL from the sampling process.
Collect the SQL statement during the sample process.
A data record is written with the SQL found in internal DB2 control blocks for the address space being monitored.
The following are valid responses:
YES will collect the SQL statement during the sample process.
NO will not collect the SQL statement during sampling.
The default is DB2SPSQL=YES.
Collect dynamic SQL statement during sampling if DB2SPSQL=NO.
A data record is written with the dynamic SQL statement found in internal DB2 control blocks for the address space being monitored. YES will produce the dynamic SQL statement each time a call to DB2 is sampled and the SQL statement is determined to be dynamic.
Note: When DB2SPSQL=YES is specified, DB2SPDYN= is ignored.
The following are valid responses:
YES will collect the dynamic SQL statement during the sample process.
NO will not collect the dynamic SQL statement during the sample process.
The default is DB2SPDYN=NO.
Sampling is not the only source of the SQL statement.
| Copyright © 2011 CA. All rights reserved. | Tell Technical Publications how we can improve this information |