SQL Server 2005 drop column with constraints

后端 未结 13 1022
一向
一向 2020-12-07 23:54

I have a column with a \"DEFAULT\" constraint. I\'d like to create a script that drops that column.

The problem is that it returns this error:

Msg 50         


        
13条回答
  •  夕颜
    夕颜 (楼主)
    2020-12-08 00:47

    I just ran into this. You can delete the column with constraints using MSSQL design view. Right click on the column you want to be dropped (with or without constraints) and you are able to delete this without any problems. Ha.. I looked stupid already.

提交回复
热议问题