How do you drop a default value or similar constraint in T-SQL?

后端 未结 6 588
萌比男神i
萌比男神i 2020-12-02 18:26

I know the syntax:

ALTER TABLE [TheTable] DROP CONSTRAINT [TheDefaultConstraint]

but how to I drop the default constraint when I don\'t kno

6条回答
  •  伪装坚强ぢ
    2020-12-02 18:30

    You can find the name of the constraint out by sp_help [table name] and then drop it by name.

    Or you can probably do this via Management studio.

提交回复
热议问题