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

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Figures<br />

2-1 Virtual storage growth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19<br />

3-1 Multi-row fetch reduces the trips across the API . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31<br />

3-2 Usage of multi-row fetch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32<br />

3-3 Example of multi-row cursor update and delete. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34<br />

3-4 CPU time (class 1) <strong>for</strong> single-row and multi-row fetch . . . . . . . . . . . . . . . . . . . . . . . . 35<br />

3-5 CPU time (class 1) <strong>for</strong> single-row and multi-row insert . . . . . . . . . . . . . . . . . . . . . . . 36<br />

3-6 Relationship between two special registers <strong>for</strong> MQTs. . . . . . . . . . . . . . . . . . . . . . . . 42<br />

3-7 Rules <strong>for</strong> query rewrite. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43<br />

3-8 Query rewrite example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44<br />

3-9 MQTs and short running queries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46<br />

3-10 Increase of BIND cost . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47<br />

3-11 Query rewrite <strong>for</strong> simple query. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48<br />

3-12 Query rewrite <strong>for</strong> join . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49<br />

3-13 Regrouping on MQT result. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50<br />

3-14 Expression® derivation example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51<br />

3-15 Star schema. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54<br />

3-16 In memory work file - Description. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57<br />

3-17 Star join access path (be<strong>for</strong>e PQ61458) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58<br />

3-18 Sparse index on work file. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59<br />

3-19 Sparse index <strong>for</strong> star join . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60<br />

3-20 Sparse index per<strong>for</strong>mance. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61<br />

3-21 Star join access path . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62<br />

3-22 In memory work file - CPU reduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63<br />

3-23 Star join workload . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64<br />

3-24 Analysis of Stage 1 and Stage 2 predicates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66<br />

3-25 Example of mismatched numeric types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67<br />

3-26 Example of mismatched string types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68<br />

3-27 Mismatched numeric data types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69<br />

3-28 Different lengths <strong>for</strong> string data type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70<br />

3-29 Access path graph in Visual Explain . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73<br />

3-30 Better filter factor estimation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75<br />

3-31 Access path improvements - Multi-column statistics . . . . . . . . . . . . . . . . . . . . . . . . . 76<br />

3-32 Mismatched data types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 78<br />

3-33 Query parallelism in V8 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79<br />

3-34 EXPLAIN example - Parallel sort. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80<br />

3-35 Multiple table group by sort . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81<br />

3-36 Multiple table order by sort. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82<br />

3-37 Table UDF - Cardinality option. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85<br />

3-38 Table UDF - Block fetch support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85<br />

3-39 SQL and BPOOL activity - Trigger 100 times . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88<br />

3-40 CPU time when invoking the trigger 100 times . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88<br />

3-41 SQL and BPOOL activity - Trigger with WHEN true only once . . . . . . . . . . . . . . . . . 89<br />

3-42 CPU time to invoke trigger but WHEN condition true once . . . . . . . . . . . . . . . . . . . . 90<br />

3-43 REXX support improvement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91<br />

3-44 DECLARE CURSOR syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94<br />

3-45 FETCH syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96<br />

3-46 Multiple DISTINCT per<strong>for</strong>mance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 110<br />

3-47 Explain of the old consistency query 31. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114<br />

© Copyright <strong>IBM</strong> Corp. 2005. All rights reserved. xi

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

Saved successfully!

Ooh no, something went wrong!