The difference between Primary key, Unique key and Foreign Key is the most common interview question for .NET as well as SQL developers.

The PRIMARY Key and UNIQUE Key constraints, both are similar and enforce uniqueness of the column on which they are defined.

Primary Key

Unique Key

Foreign Key

I hope you enjoyed it.