19.06.2013 Views

DB2 UDB for z/OS Version 8 Performance Topics - IBM Redbooks

DB2 UDB for z/OS Version 8 Performance Topics - IBM Redbooks

DB2 UDB for z/OS Version 8 Performance Topics - IBM Redbooks

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

DSNTIAUL without multi-row fetch<br />

The results of the per<strong>for</strong>mance measurement between HPU and <strong>DB2</strong> V8 DSNTIAUL are<br />

summarized in Table 10-6 <strong>for</strong> the case where DSNTIAUL is not using multi-row fetch.<br />

Table 10-6 HPU V2.2 vs. <strong>DB2</strong> V8 DSNTIAUL (no multi-row)<br />

Test case HPU V2.2 <strong>DB2</strong> V8 DSNTIAUL % Difference<br />

CPU Elapsed CPU Elapsed CPU Elapsed<br />

Case 1 11.89 62 186.99 239 1472.66 285.48<br />

Case 2 9.44 61 N/A N/A N/A N/A<br />

Case 3 13.57 59 186.77 238 1276.34 303.38<br />

Case 4 9.67 46 148.46 166 1435.26 260.86<br />

Case 5 18.00 58 184.71 236 926.16 306.89<br />

Case 6 13.93 46 146.33 163 950.46 254.34<br />

Case 7 12.87 45 8.23 45 -36.05 0<br />

Case 8 17.80 59 191.34 237 974.94 301.69<br />

Case 9 12.51 45 1.75 22 -86.01 -51.11<br />

Case 10 2.39 22 1.75 22 -26.77 0<br />

Parallel 15.33 24 N/A N/A N/A N/A<br />

DSNTIAUL can use an index so one would assume that DSNTIAUL may have a slight<br />

advantage over the UNLOAD utility. However, the measurement cases illustrate otherwise.<br />

DSNTIAUL was the larger consumer of CPU time and also typically had the longer elapsed<br />

time, although two test cases showed DSNTIAUL being the better per<strong>for</strong>mer. However, when<br />

you compare DSNTIAUL with HPU, the results are extraordinary. HPU outper<strong>for</strong>med<br />

DSNTIAUL by using less than 10% of the CPU time.<br />

Nearly every unload product is written with the assumption that users will unload a large<br />

percentage of the available data, usually in the 50 - 100% range. In these instances, it may be<br />

better to scan the entire table rather than using an index.<br />

However, there are times when you may want to unload a small percentage of the rows,<br />

perhaps 10 - 20% and you know an index exists that allows access to the table data. In this<br />

case, a scan of the table may result in worse per<strong>for</strong>mance than if an SQL statement were<br />

executed directly by <strong>DB2</strong>; you may then see better per<strong>for</strong>mance with DSNTIAUL than with<br />

HPU.<br />

If you are using HPU and you have a query where using the SQL might per<strong>for</strong>m better than a<br />

table space scan, use the <strong>DB2</strong> FORCE parameter. This causes HPU to pass the query to<br />

<strong>DB2</strong> <strong>for</strong> execution and may result in better per<strong>for</strong>mance. This is evident in case 10 which is<br />

the same as case 9 except <strong>DB2</strong> FORCE is used. The results are once again dramatic; there<br />

is a 6X improvement in CPU time with the exact same elapsed time.<br />

Note: DSNTIAUL cannot unload from an image copy data set so the results are N/A <strong>for</strong><br />

case 2.<br />

Chapter 10. Per<strong>for</strong>mance tools 375

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!