Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to drop column, re: constraint 1

Status
Not open for further replies.

azoe

Technical User
Feb 21, 2005
175
US
I added a column to a table like this:
alter table MyTable
Add ColumnX varchar(12)

Then I tried to delete that column:

alter table MyTable
Drop ColumnX

But it says: 'ColumnX' is not a constraint
Could not drop constraint

This is the first time I have added or tried to delete a column. I had to look up constraint to see what it was. I think it has to do with whether it can be Null or not. It can be. In Help it said something about a constraint name but I don't recall naming anything but the column. So how do I remove that column?

Thank you.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top