All Questions
1 question
2
votes
1
answer
208
views
How to constrain many-to-many to mark a single record as a "default"? [duplicate]
Suppose I have the following entities:
customer(id, name)
template(id, name)
With a junction table:
customer_template(id, customerId, templateId, is_default)
A customer may have any number of ...