Using Key Find Routines

The Key Find routines work just as the other find and find range routines do, except that the Key Find routines return only the key fields from the index. They do not return entire records from data files. Key find routines only read the data for inquiry, not for update or modification.

These Key Find routines are designed to give a performance advantage when only the key fields are needed. The performance advantage results from the elimination of the need to perform a second read for each find call. For a regular find or range find call, the routine reads the index to locate the record, then reads the table to get the actual record. In the case of a key find, the routine reads the Index without subsequently accessing the table, because the index contains all the requested information (the key fields).