Product Documentation

Database Administrator's Guide

Previous Topic

Next Topic

MAX_HANDLES

MAX_HANDLES

MAX_HANDLES can improve the performance of a rebuild.

The rebuild function does a scan on the data file. At the end of the scan the number of records (max key values) is known. An output buffer is used to write sorted key values to disk when needed, that is, when all keys can't fit into data buffers. Data buffers contain unsorted key values put there the data file is scanned. When all data buffers or the pointer area are full, the logic sorts the pointers in the buffer by key value and then writes all data in data buffers to disk. Output is done in output buffer sized chunks to sort work files, which are c-tree data files.

Based on the actual number of keys (number of records) and key size + pntr size the fraction of key values that can stored in the given memory (MAX_K_TO_USE) is known. If the memory is large enough then just that amount of memory is needed. If the memory is not large enough then the # of file handles needed to store the values on disk is computed, limited by the MAX_HANDLES value.

Default: 255

See Also

MAX_K_TO_USE

TOCIndex