Candidate key processing determines which column conditions can be used for optimized reading, and attaches a list of low and high values to the accepted columns.
The system does not know whether the column is actually part of a key, or if it is the primary column within the key. This information becomes available later. For example, after opening a VSAM KSDS file on z/OS, the offset and length of the key become available depending on whether the default index or an alternate index is used.
If candidate key processing encounters an unacceptable condition for a column, all conditions for the column and the optimization level are also excluded for optimized reading, but they are retained for post-read qualification processing. For a list of unacceptable conditions, see
Conditions Skipped by the Optimized Read Process.
If all WHERE clause conditions for a column are accepted, a list of low and high value pairs are created using the "internal form." Numeric values are either 31 digits or 30 digits preceded by a negative sign (-).
Where only one of the boundaries have been set for the LE, LT, GE, or GT conditions, the system inserts the missing low or h condition, typically using binary zeros or X'FF'.