Table space compression
Considerations when using table space compression
Note the following considerations when using table space compression with REORG PLUS:
- When both of the following conditions exist, specify a member subsystem ID (SSID) for your reorganization job instead of a group attachment name. Ensure that the Db2 version of the SSID that you specify corresponds to the version of the Db2 load library that you specify in your STEPLIB.
- You are running REORG PLUS in a data-sharing environment.
- The subsystems in your data sharing group are not all at the same Db2 version level.
- Reorganizing a large number of compressed partitions might result in constrained resources. If you encounter this problem, consider specifying fewer partitions in a single job. (Whether the number of compressed partitions that you have is considered to be a large number depends on your environment.)
- REORG PLUS reports the percentage of compressed rows in messages BMC50512I and BMC50522I. This percentage does not include rows that are compressed by an EDITPROC.
- When REORG PLUS invokes DSNUTILB, compression is handled by DSNUTILB. For information about how compression is handled for these jobs, see the documentation for the REORG utility in the IBM Db2 Utility Guide and Reference.
Building a dictionary
REORG PLUS builds a new dictionary when any of the following conditions exist:
- The value of KEEPDICTIONARY is NO.
- The value of KEEPDICTIONARY is YES, and one of the following conditions is in effect:
- A dictionary does not exist.
- REORG PLUS is converting your data from BRF to RRF and the value of the Db2 subsystem parameter HONOR_KEEPDICTIONARY is NO.
- You are rebalancing partitions of table space with compression. (For more information about partition rebalancing, see Partition-rebalancing.)
- One of the following definition changes is pending on the table space:
- An alter of the table space buffer pool or segment size
- A table alter that changes the limit key
After REORG PLUS builds the dictionary, REORG PLUS uses it to compress the data rows. REORG PLUS stores the dictionary in the BMCDICT table until the reorganization completes.
Note the following considerations about building a dictionary:
- REORG PLUS reserves enough pages for the largest dictionary size.
- If REORG PLUS does not unload enough rows to build a complete dictionary, REORG PLUS
- Does not compress any rows
- Builds a non-optimal dictionary for future use
- For partition-by-growth table spaces, whether REORG PLUS builds a new dictionary depends on the value of the ORDER option, as follows:
- For ORDER NO, REORG PLUS ignores KEEPDICTIONARY YES and builds a new dictionary for each added partition that has enough rows to build a dictionary.
- For ORDER YES, REORG PLUS copies the dictionary for each added partition from the previous partition, regardless of the KEEPDICTIONARY value.
Keeping a dictionary
If the value of KEEPDICTIONARY is YES and a dictionary already exists, REORG PLUS uses the dictionary for compression. When using the existing dictionary, REORG PLUS compresses all of the data rows and does not have to spend processing time identifying patterns and building the dictionary.
Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*