Do link tables need a meaningless primary key field?

前端 未结 12 1524
你的背包
你的背包 2020-12-08 14:05

I am working on a couple of link tables and I got to thinking (Danger Will Robinson, Danger) what are the possible structures of a link table and what are their pro\'s and c

12条回答
  •  陌清茗
    陌清茗 (楼主)
    2020-12-08 14:40

    i've used both, the only benefit of using the first model (with uid) is that you can transport the identifier around as a number, whereas in some cases you would have to do some string concatenation with the composite key to transport it around.

    i agree that not indexing the foreign keys is a bad idea whichever way you go.

提交回复
热议问题