database tuning using partitioned tablespaces and clustering indexes

2
Category: AMS Title: Database Tuning using partitioned tablespaces and clustering indexes Summary: Our project is a worldwide CRM tool which is primarily used for pricing of IBM products. Our team serves as Information Warehouse for this pricing application. It also provide data for reports to other business units for planning future sales & marketing strategy and other purposes. We have some tables which are queried frequently by these business units. Data in these tables is expected to grow abruptly with time. We were facing some performance issues in loading and pulling data to & from these tables. Reporting queries on these tables were also taking much time to fetch data. Proposed Solution: After deep analysis of data and structure of these tables, we proposed following solution : Create a partitioned tablespace for these tables based on boundary values that are defined for specific columns. The columns are selected so that number of pages DB2 needs to access for searching a specific record is minimum. Also, we need to create the clustered indexes on these tablespaces based on the specific columns selected above. A clustering index determines how rows are physically ordered (clustered) in a table space. Using a clustered index is an advantage when groups of data that can be clustered are frequently accessed by some queries. In unload cards and report queries, use the columns on which clustering index is created in the same order of index in JOINS and WHERE clause. A regular REORG and RUNSTAT should be scheduled on these tables. Benefits Realized: Several concurrent utility jobs can run, for example, load all partitions of a table space concurrently. Because you can work on part of your data, some of your operations on the data might require less time. So, it makes parallelism possible. Using clustering indexes significantly optimized the performance of queries as only related data partitions were scanned. It helped in improving manageability of these large tables as each partition can be administered independently.

Upload: paresh-bhatia

Post on 10-Nov-2015

213 views

Category:

Documents


0 download

DESCRIPTION

Database Tuning Using Partitioned Tablespaces and Clustering Indexes

TRANSCRIPT

Entire abstract should not be more than two pages

Category: AMSTitle: Database Tuning using partitioned tablespaces and clustering indexes

Summary:

Our project is a worldwide CRM tool which is primarily used for pricing of IBM products. Our team serves as Information Warehouse for this pricing application. It also provide data for reports to other business units for planning future sales & marketing strategy and other purposes. We have some tables which are queried frequently by these business units. Data in these tables is expected to grow abruptly with time. We were facing some performance issues in loading and pulling data to & from these tables. Reporting queries on these tables were also taking much time to fetch data.Proposed Solution:

After deep analysis of data and structure of these tables, we proposed following solution :

Create a partitioned tablespace for these tables based on boundary values that are defined for specific columns. The columns are selected so that number of pages DB2 needs to access for searching a specific record is minimum.

Also, we need to create the clustered indexes on these tablespaces based on the specific columns selected above. A clustering index determines how rows are physically ordered (clustered) in a table space. Using a clustered index is an advantage when groups of data that can be clustered are frequently accessed by some queries.

In unload cards and report queries, use the columns on which clustering index is created in the same order of index in JOINS and WHERE clause.

A regular REORG and RUNSTAT should be scheduled on these tables.Benefits Realized: Several concurrent utility jobs can run, for example, load all partitions of a table space concurrently. Because you can work on part of your data, some of your operations on the data might require less time. So, it makes parallelism possible.

Using clustering indexes significantly optimized the performance of queries as only related data partitions were scanned.

It helped in improving manageability of these large tables as each partition can be administered independently.

It also facilitated better optimization of storage cost and faster online data roll-in/roll-out.