5
Reply

How to create composite key through SQL 2008 GUI

Prasad Godbole

Prasad Godbole

Jul 7 2011 3:05 AM
2.8k
Hi ,

We have a table and want to add composite key through SQL 2008 GUI

The table is  "T_UserDetails"  and it conatins the following fields

Field                        Data Type                
Id                         int
RegNo                   varchar(100)
UserFName             varchar(50)       
UserLName             varchar(50)       

We want that using "Id" and "RegNo" field the record should be uniquely identify.

We have tried to set primary key to both columns by selecting in design mode but its disabling the primary key option. Also we have tried to do this through "Manage Indexes and Keys" but its not showing column names.

Through SQL create table script we can set this but its not happening through SQL 2008 GUI

Please suggest steps to do through GUI.


Many Thanks
Prasad

Answers (5)