Although it is not a requirement, it is a good idea to assign a primary key to one of the fields in your database. You always want to avoid having two duplicate records in a table. Setting a field as a primary key serves as insurance against it. If a field is set as a primary key, the computer will alert you when you attempt to type duplicate data into that field. In fact, you won't be able to move or save the table until you correct it. Good examples of a primary key field include Social Security numbers, employee ID's, or driver's licenses.
When you create a table originally, Access will ask if it can create a primary key
field for you. If you decide to create it yourself, you can use the Primary Key
button on the toolbar when you are in a table's design mode. Simply choose the field
where records won't have duplicates and click the button.
We will demonstrate by making the Member Number field the primary key field.
![]() |
Click here to see a video demo. |
It should be noted that several fields can be made as primary key fields. Also, once a primary key is set, you can get rid of it by choosing that field and clicking the Primary Key button off.
last modified 10/20/98 pjm