Hi all :)

Currently now I used MS SQL Server Management Studio 2008.

I have an existing table with data already store on that table.
Table Name :
Application

Column :
Categories (nvarchar(1), null)
Sequence (nvarchar(1), null)
Detail (nvarchar(150), null)

I would like to ask how to add primary key to column Categories and Sequence ?

Thank you in advance !

in Oracle you'd do something like
CREATE UNIQUE INDEX "MYSCHEMA"."MYTABLE_PK" ON "MYSCHEMA"."MYTABLE" ("CATEGORIES", "SEQUENCE")

Of course you could never use the name "SEQUENCE" for a column in Oracle as it's a reserved word (as it is in MS SQL Server, I'm kinda surprised it let you create a column with that name...).

ALTER TABLE Persons
ADD CONSTRAINT pk_PersonID PRIMARY KEY (P_Id,LastName)