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.

If explicit clustering <strong>for</strong> a table is removed (changed to NOT CLUSTER), that index is still used<br />

as the implicit clustering index until a new explicit clustering index is chosen.<br />

5.5.4 DPSI and impact on utilities and queries<br />

With <strong>DB2</strong> V7, secondary indexes on partitioned tables are non-partitioned indexes.<br />

Secondary indexes cannot be physically partitioned. They can only be allocated across<br />

multiple pieces to reduce I/O contention. <strong>DB2</strong> V8 introduces the ability to physically partition<br />

secondary indexes. The partitioning scheme introduced is the same as that of the table<br />

space. That is, there are as many index partitions in the secondary index as table space<br />

partitions, and index keys in partition “n” of the index reference only data in partition “n” of the<br />

table space. Such an index is called a Data-Partitioned Secondary Index (DPSI).<br />

Description<br />

When an index is created and no additional keywords are specified, the index is<br />

non-partitioned. If the keyword PARTITIONED is specified, the index is partitioned. The index<br />

is both data-partitioned and key-partitioned when it is defined on the partitioning columns of<br />

the table. Any index on a partitioned table space that does not meet the definition of a<br />

partitioning index is a secondary index. When a secondary index is created and no additional<br />

keywords are specified, the secondary index is non-partitioned (NPSI). If the keyword<br />

PARTITIONED is specified, the index is a data-partitioned secondary index (DPSI).<br />

You create a DPSI by specifying the new PARTITIONED keyword in the CREATE INDEX<br />

statement and defining keys on some columns that coincide with the partitioning columns of<br />

the table. When defining a DPSI, the index cannot be created as UNIQUE or UNIQUE<br />

WHERE NOT NULL. This is to avoid having to search each part of the DPSI to make sure the<br />

key is unique.<br />

Benefits of DPSIs are:<br />

► Allow partition-level operation <strong>for</strong> utilities operating on secondary indexes such as REORG<br />

INDEX, RUNSTATS INDEX<br />

► Eliminate contention on index pages <strong>for</strong> utilities operating on partition level with DPSI.<br />

► Utilize concurrent LOAD PART more efficiently while inserting DPSI keys<br />

► Eliminate the BUILD2 phase during Online REORG of a partition<br />

► Reduce data sharing overhead<br />

For a detailed description of DPSIs see <strong>DB2</strong> <strong>UDB</strong> <strong>for</strong> z/<strong>OS</strong> <strong>Version</strong> 8: Everything You Ever<br />

Wanted to Know, ... and More, SG24-6079.<br />

Per<strong>for</strong>mance<br />

In this section the per<strong>for</strong>mance impact of DPSIs on utilities and queries is evaluated.<br />

Per<strong>for</strong>mance measurement description<br />

For this measurement we used:<br />

► z/<strong>OS</strong> V1R3<br />

► <strong>DB2</strong> <strong>for</strong> z/<strong>OS</strong> V8 in NFM<br />

► <strong>IBM</strong> z900 Series 2064 4-way processor<br />

► ESS model F20 with FICON channels<br />

Per<strong>for</strong>mance measurement result <strong>for</strong> utilities and DPSIs<br />

We used a partitioned table of 20 M rows with 10 partitions<br />

248 <strong>DB2</strong> <strong>UDB</strong> <strong>for</strong> z/<strong>OS</strong> <strong>Version</strong> 8 Per<strong>for</strong>mance <strong>Topics</strong>

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

Saved successfully!

Ooh no, something went wrong!