I've the the following ERD
I want that a customer Klant
can only place one order Bestelling
per day.
I'm not sure how I can accomplish this, I think that I have to use unique index here. Could someone show me how it is done?
I've the the following ERD
I want that a customer Klant
can only place one order Bestelling
per day.
I'm not sure how I can accomplish this, I think that I have to use unique index here. Could someone show me how it is done?
Yes, you can add a unique constraint on the fields klantnr and besteldatum.
alter table bestelling
add constraint un_bestelling unique (klantnr, besteldatum)