How to automatically generate DDL change scripts when creating or editing tables in SQL Server Management Studio

If we want SQL Server Management Studio to create a DDL change script for us when we create or change a table we can configure this in the Options -> Designers -> Tables and Database Designers screen as shown below…

When we have the ‘Auto generate change scripts’ option selected above SMSS will popup a window with the DDL change script each time we create or edit a table.

The example below shows the change script shown after I’ve added a new column called Fee to the Courses table…

Create change scripts in SQL Server Management Studio

Unfortunately it seems this functionality only works on tables.

Leave a Reply

Your email address will not be published. Required fields are marked *