How would I be able to define a Unique constraint on a composite PK which consists of 6 different columns?
I am having some trouble inserting data into this table because of a PK constraint. Since it's 6 columns, I'm not sure how to group by and count the line items which are duplicated.
I read somewhere that instead of me doing it, I can have the DB take care of this automatically by putting a unique constraint on this composite key and then it'll insert based on that.
Im a little confused but thought I'd give it a go since I thought my composite key I defined was exactly for uniqueness.
↧