Indexing Data


10 Minute Guide to Microsoft Access 2002
By Joe Habraken
Table of Contents
Lesson 16.  Sorting, Filtering, and Indexing Data

Indexing Data

Although not a method of manipulating data like a sort or a filter, indexes provide a method for speeding up searches, sorts, and filters by cataloging the contents of a particular field. The primary key field in a table is automatically indexed. If you have a large database table and frequently search, sort , or filter by a field other than the primary key field, you might want to create an index for that field.


Can't Be Indexed You can't index a field whose data type is Memo, Hyperlink, or OLE Object. There is no way for Access to verify the content of fields containing these types of entries, making it impossible to create an index.

To index a field, follow these steps:

  1. Open the table in Design view.

  2. Select the field that you want to index.

  3. In the Field Properties pane on the General tab, click in the Indexed box.

  4. From the Indexed field's drop-down list, select either Yes (Duplicates OK) or Yes (No Duplicates), depending on whether that field's content should be unique for each record (see Figure 16.5). For example, in the case of indexing a last name field, you would want to allow duplicates (Duplicates OK), but in the case of a Social Security number field where you know each entry is unique, you would not want to allow duplicates (No Duplicates).

    Figure 16.5. To index a field, set its Indexed value to one of the Yes choices.

  5. Save your changes to the table's structure by clicking the Save button on the Design toolbar.

  6. Close the Design view of the table.

Indexes aren't glamorous. They work behind the scenes to speed up your searches and filters. They don't really have any independent functions of their own.

In this lesson, you learned how to sort, filter, and index your database tables. In the next lesson, you learn how to create a query using the Query Wizard.


10 Minute Guide to Microsoft Access 2002
10 Minute Guide to Microsoft Access 2002
ISBN: 0789726319
EAN: 2147483647
Year: 2000
Pages: 160
Authors: Joe Habraken © 2008-2017.
If you may any questions please contact us: