How Can We Represent Secondary Keys?
In many cases, the word key indicates a field (or fields) whose value uniquely identifies a record. This is
usually called the primary key. Sometimes, however, applications need to access and process records by
means of a secondary key, one that is different from the primary key. Secondary keys may be a unique
secondary key (such as a professor’s name) or a nonunique secondary key (such as a customer’s zip
code). In this section, we use the term set to refer to all records having the same value of a nonunique
secondary key; for example, a set of records having zip code 98040.
Both linked lists and indexes are used to represent secondary keys, but linked lists are practical only for
nonunique keys. Indexes, however, can be used for both unique and nonunique key representations.