Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 How to Drop Primary key constrain.

Author  Topic 

hspatil31
Posting Yak Master

182 Posts

Posted - 2011-07-02 : 07:51:25
Dear All,

I am having one table with huge data on that i had already primary key constrain means Cluster index.

Now i want to remove that primary key constrain and set the Non-Cluster index.

Can anyone help me how to do this ?

Thanks and Regard's
Harish Patil

GilaMonster
Master Smack Fu Yak Hacker

4507 Posts

Posted - 2011-07-02 : 09:19:31
ALTER TABLE <table name> DROP CONSTRAINT <Constraint name>

You'll have to drop all foreign keys first.

--
Gail Shaw
SQL Server MVP
Go to Top of Page
   

- Advertisement -