MySql question with multi-field primary keys
I have a table with a primary key which is built from three 开发者_运维技巧columns. In an other table I would like to reference to them as one single column foreign key. How can this be resolved? Maybe an id alias? Or how can this be resolved?
There is no good way to do this, just use all three as a foreign key. You could introduce an additional unique-values column on the original, and reference that, but it isn't a great approach.
精彩评论