I'm trying to find out all dependencies for given views.
I tried all available method
- EXEC sp_depends
- EXEC sp_MSdependencies
- sys.sql_dependencies table

All above work only few views and not all.
Why is this information available for only few and not all views?
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

dependencies only work if sql is able to keep track of the dependency when the object is created....not accurate really in versions previous to 2008.
rahulsuryaAuthor Commented:
Can i rebuild dependencies or is there a way i can find out all base tables a view uses?
Raja Jegan RSQL Server DBA & Architect, EE Solution GuideCommented:
SQL Server's internal tracking of dependencies is not accurate and hence there might be some information missing for some views..
And hence the below third party tools

* Red gate Dependency Tracker (http://www.red-gate.com/products/SQL_Dependency_tracker/index.htm)
* Apex SQL Clean (http://www.apexsql.com/sql_tools_clean.asp)

gained more popularity in these areas..

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
you could, but there isn't an easy way to go it, unfortunately.

apexsql.com has a dependency tracker that is really good for doing this. I use it exclusively rather than rely on how sql tracks the dependencies for 2005 and prior instances.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft SQL Server 2005

From novice to tech pro — start learning today.