MS SQL DROP DEFAULT CONSTRAINT
Posted on 2014-12-27
I noticed, from the object sys.default_constraints, that MS SQL generates individual default constraints for each field set with a default value.
Please, note that I set the default values with one Alter table table1 add constraint tableconstr1 default ... for ...., and this statement was built using information from information_schema.columns.
Is there a way to drop all the default constraints generated automatically by MS SQL with one statement like
ALTER table table1 DROP CONSTRAINT tableconstr1 (name previously used in the statement above).
Thanks in advance for your time.