Difference Between Primary Key And Surrogate Key
Revision as of 14:10, 1 April 2015 by 171.50.173.25 (talk)
The primary key and the surrogate key both are unique identifiers for the entity in the modelled world or object in the database. However , they have a difference which is based on the type of the database being used.
Primary Key | Surrogate Key |
---|---|
Primary Key is a constraint that ensures that the column or set of columns so designated should not have duplicate or null values . | Surrogate Key is a column or set of colums that can be declared as primary key instead of a natural or real key. |