December 5, 2012 at 2:01 pm
Not sure if this is the right place, so if its not, please direct me to it.
I want to generate a list of all objects in a database which are no longer valid (reference invalid tables, columns, etc...). Is there a way to do this? Any insight would be appreciated!
Thanks,
Michael
December 5, 2012 at 2:07 pm
i've got this script i posted here on SSC multiple times that seems to do a nice job for me;
for Invalid Objects, it's not like oracle, where there is a column to query to test whether something was compiled successfully.
note this doesn't give you a list of what is broken NOW, but rather tries to recompile everything, and reports what fails to compile.
also note it's expecting a coding convention of a single space between CREATE PROC/VIEW/FUNCTION
--expected
CREATE PROC
--fails
CREATE PROC
so if you have objects that have more whitespace between them, it may report them as invalid, when they are actually ok.
Lowell
December 5, 2012 at 2:12 pm
That is perfect. Thank you!
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply