? List all tables used in stored procedures and views ?

  • Hi,

     

    Maybe I'm googling this wrong, but I'm looking to find out how I can list all the tables being used byu all the Stored procs and views?

     

    Thanks

    Joe

     

  • Sorry

     

    Also alot of tables are being called from another Database

  • You're looking for the table-valued functions sys.dm_sql_referenced_entities() and sys.dm_sql_referencing_entities().  These will not show cross database dependencies.  You may also want to look at Redgate's SQL Dependency Tracker 3.

    Drew

    J. Drew Allen
    Business Intelligence Analyst
    Philadelphia, PA

Viewing 3 posts - 1 through 2 (of 2 total)

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