An index is a data structure that speeds retrieval or enforces certain constraints, such as uniqueness, on the records in a table. This data structure is separate from the table and can be deleted and recreated without affecting table data. There are three types of indexes:
An index is an organized set of pointers to the rows of a database. Each index is based on the values of data in one or more columns.
A unique index prevents the table from containing two or more rows with the same value in the index key.
A primary key is a column or set of columns used to uniquely identify a row. Primary keys are required for referential integrity relationships. A table may contain at most one primary key.
You can specify a primary key when you create a new table or when you alter an existing table. You can alter or drop a primary key. The method for creating, altering, and dropping a primary key is the same as for an index. The only difference is that the Type option must be set to Primary Key.
You must define all columns involved in a primary key either as NOT NULL or NOT NULL WITH DEFAULT. When you define a primary key for a table, the Column Definition Grid on the Create/Alter Table dialog box is modified automatically. Any column that was defined with nulls allowed (False in the Not Null column) is changed to NOT NULL (True in the Not Null column). You can change the value in the Column Definition Grid to w/Default if you wish.