跳至內容
選單
此問題已被標幟
4675 瀏覽次數

Hello,


I am trying to create a one to one relationship between two of my models (A and B). This is to avoid that multiple people using the system accidentally assign duplicate matches (i.e. when A.id1 is associated with B.id1, none of these IDs can be used in other matches).

This seems like quite an intuitive use case, but everywhere I see that the One2one relationship has actually been deprecated for a long time, and I keep finding hacks to simulate this behaviour.

I'm trying to understand why this is the case, as I am sure I am missing some important detail. If someone could advise, it would be much appreciated.

Thanks


頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
0
10月 23
1286
3
4月 20
3509
1
2月 20
2225
0
10月 18
3881
1
3月 15
4270