A primary key is used to identify a unique table row. If you define a primary key, an index is created for the specified column.
The uniqueness constraint and NOT NULL constraint apply to a column for which a primary key is defined. The uniqueness constraint does not allow a duplication of data in the key (a column or a group of columns). That is, all data in the key is always unique. The NOT NULL constraint does not allow a null value in any of the columns in the key.
Define a primary key for a column that can identify a unique row. If there is more than one column that can identify a unique row (candidate key), select one of the candidate keys as the primary key. Among the keys in the table, define the one that is most important and that is to be controlled by the uniqueness and NOT NULL constraints as the primary key.
To define a primary key, specify the PRIMARY KEY option in the CREATE TABLE SQL definition statement.