Primary Key - Unique Identifier
An important part of determining the fields for each table is deciding which field (if any) is suitable as the primary key.
The power of a relational database is the ability to bring a lot of information together quickly. For this to work efficiently and effectively, Microsoft® Access needs to be able to identify unique records. For this reason, one field or a set of fields needs to be unique. This can be a unique identification number such as a Medicare number, Employee ID number, Pension number, etc.:
A primary key cannot contain duplicate values, e.g. a person’s last name is not suitable as a primary key as there is often more than one person with the same last name;
A primary key cannot contain null values, therefore a field such as a phone number is not suitable, as you may not know the person’s phone number when you first enter them into the database;
Also, if the information contained in the Primary Key is likely to be altered, then it is best to avoid this field as well.
If a unique identifier cannot be identified (which is more than likely), you can add a field, which will automatically increase sequentially by one, thus providing the record with a unique identifier.
An important part of determining the fields for each table is deciding which field (if any) is suitable as the primary key.
The power of a relational database is the ability to bring a lot of information together quickly. For this to work efficiently and effectively, Microsoft® Access needs to be able to identify unique records. For this reason, one field or a set of fields needs to be unique. This can be a unique identification number such as a Medicare number, Employee ID number, Pension number, etc.:
A primary key cannot contain duplicate values, e.g. a person’s last name is not suitable as a primary key as there is often more than one person with the same last name;
A primary key cannot contain null values, therefore a field such as a phone number is not suitable, as you may not know the person’s phone number when you first enter them into the database;
Also, if the information contained in the Primary Key is likely to be altered, then it is best to avoid this field as well.
If a unique identifier cannot be identified (which is more than likely), you can add a field, which will automatically increase sequentially by one, thus providing the record with a unique identifier.