How to find (and recompile) all invalid (dependant) database objects caused by data structure change?
Posted on 2008-10-23
I've worked with Oracle for a long time and just come to MS SQL Server 2005 recently.
We are going to make a lot of structural changes to our database, it is a large finance system with literally over 1000 tables and views.
When I worked with Oracle, when a referenced object (e.g. a table) is changed, all the objects that depend on it, like views, procedures or triggers, are marked invalid, and in the development tool I used (PL/SQL Developer), there's an option to recompile all these invalid objects. Even if due to the structural change a recompile doesn't succeed, it's easy to keep track what objects we should look at.
Could someone shed a light, what's the best way to go about it for MS SQL Server 2005? I haven't found anything in the Management Studio, is there any specific development tool supporting this?
Many thanks in advance!