What is difference between unique key with 'not null' constraint and primary key?

后端 未结 4 1138
深忆病人
深忆病人 2020-12-31 11:02

I want to know difference between these two key.

When the Unique key with not null constrain in terms of how they are stored in database

and wh

4条回答
  •  傲寒
    傲寒 (楼主)
    2020-12-31 11:41

    Primary key cannot be null, there can be only one per table.

    Unique keys can contain nulls, and you can have more than one per table.

提交回复
热议问题