What's the best practice for primary keys in tables?

前端 未结 21 2171
别那么骄傲
别那么骄傲 2020-11-22 14:02

When designing tables, I\'ve developed a habit of having one column that is unique and that I make the primary key. This is achieved in three ways depending on requirements

21条回答
  •  南笙
    南笙 (楼主)
    2020-11-22 14:19

    You should use a 'composite' or 'compound' primary key that comprises of multiple fields.

    This is a perfectly acceptable solution, go here for more info :)

提交回复
热议问题