mysqlsqldatabaseprimary-keyunique-key

Difference between primary key and unique key


I'm using a MySQL database.

In which situations should I create a unique key or a primary key?


Solution

  • Primary Key:

    Unique Key: