sql server Invalid Views(including ambiguous columns)

  • Hi,

    I need to check for invalid views in my DB (including ambiguous columns)

    does anyone can recommend how to do that ?

    I saw some code from 2009 , but when i  execute it (Job) it's taking ages ...

  • Have you tried checking for build warnings in SSDT?

    If you haven't even tried to resolve your issue, please don't expect the hard-working volunteers here to waste their time providing links to answers which you could easily have found yourself.

  • check sp_refreshview

    EXEC sp_refreshview '[View_SCHEMA].[ViewName]'


    Learn to play, play to learn !

    Dont drive faster than your guardian angel can fly ...
    but keeping both feet on the ground wont get you anywhere :w00t:

    - How to post Performance Problems
    - How to post data/code to get the best help[/url]

    - How to prevent a sore throat after hours of presenting ppt

    press F1 for solution, press shift+F1 for urgent solution 😀

    Need a bit of Powershell? How about this

    Who am I ? Sometimes this is me but most of the time this is me


    i have a  cursor that execute all my views in sp_refreshview

    and then my output is the views that cant run .


    now, my new challenge is how to run it in a procedure or ssis ?


    when i just execute the code by my self , it takes few minutes ...while im trying to execute it with ssis or job or proc


    it takes really long time



Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply