Groups | Blog | Home
all groups > sql server (microsoft) > june 2006 >

sql server (microsoft) : Unique key on 2 fields in which 1 is non unique under the first unique key


Vicky
6/23/2006 4:53:55 AM
Hi ,
I want to create a unique field on 2 columns named (customer_id ,
is_default ).
but the problem I have in having this is in my customer table
customer_id field is unique and can have more than 4-5 values for
is_default field. hence if I want to create a unique key composed of
the above 2 keys then it would not happen as my same customer_id have
4-5 is_default values and I want them to be unique for each combination
in the table.....

so any suggestion with this are highly appreciated ....

Thanks
Vicky
Vicky
6/23/2006 5:18:46 AM

[quoted text, click to view]
AddThis Social Bookmark Button