Indexes speed the processes of finding and sorting records. You should create indexes for fields that are frequently used in searches and in sorting. You can create an index on a new or existing table. An index can be made of one or more fields. This chapter presents a number of procedures that use Data Definition Language statements to define indexes and primary keys.
You can create an index while creating a table by using the CONSTRAINT clause with the CREATE TABLE statement. The procedure in Hands-On 21-1 creates a new table called Supplier1 with a unique index called idxSupplierName based on the SupplierName field.