SQL Server – Looping through a table list to disable, renable constraints or add a new column

The Need: The basic need a lot of times is to loop through a list of something and do something else for the items in the list that qualify - like disabling/re-enabling constraints for a set of tables or adding/dropping a column etc. We will see three examples below that act on such a list … Continue reading SQL Server – Looping through a table list to disable, renable constraints or add a new column

Advertisements