OPEN PARTITIONS Option

The OPEN PARTITIONS option applies only to partitioned structures. The OPEN PARTITIONS option specifies the number of different partitions of the structure that can be in use concurrently for the database as a whole. The default value for the OPEN PARTITIONS option is 1 and the maximum value is 15. An attempt to open more partitions than specified will result in a LIMITERROR error.

PARTITION Option

Partitioning is used for structures which would otherwise require very large files. It reduces the amount of disk or pack space required when only a small portion of the file is used at any single time.

Only embedded structures can be partitioned. The embedded structure is partitioned based upon the value of an item in the disjoint data set which contains the embedded structure. The data item that controls the partitioning is the partition key. The partition key serves as the key of the partitioning set.

The system automatically keeps track of the partitions which currently exist by using a structure called the partition directory. There is a record in the partition directory for each partition in the database. The first time a record in a partitioned structure is referenced after the value of the partition key has changed, the system automatically looks in the partition directory to determine if the partition exists. If it does, the file is opened and accessed in the normal manner. If it does not, the proper file is created, and a record for it is created in the partition directory. Subsequent references to the same partition seek records in the same partition file, thereby incurring very little overhead beyond that of a nonpartitioned structure.

The set name specified following the PARTITION keyword identifies the partitioning set. The key of the partitioning set must be an alpha item or numeric item with a length of 17 or less. Alpha items must contain only letters and digits, and the contents of the item must be left-justified with blank fill. If the key contains embedded blanks or special characters, a data exception occurs at run time. The set can allow duplicates, but the keys of existing records must not be changed.

Note: The Enterprise Database Server does not support the addition of a partitioned structure to an existing unpartitioned database.