Forcing Management Studio to use ALTER TABLE instead of DROP/CREATE

前端 未结 4 1023
暗喜
暗喜 2021-01-11 13:49

I\'m wondering if is there a way to force MSSQL Management Studio to produce a script like this:

ALTER TABLE Mytable
ADD MyCol bit NOT NULL
CONSTRAINT MyColD         


        
4条回答
  •  野趣味
    野趣味 (楼主)
    2021-01-11 14:30

    Just to augment @marc_s's answer. In case you still can't generate the change script 'cause your table needs to be recreated, you need to go to Tools -> Options and under Designers -> Table and Database Designers unmark the option Prevent saving changes that require table re-creation.

提交回复
热议问题