Table uses table

  • Both ApexSQLEditor and TOAD for SQL Server can show the tables a table uses or is dependent on. The stored procedure sp_depends shows everything but tables. Are there a way to show what tables a table depends on?

    Best regards

    Jesper

     

     

  • jseper

    check this system table - sysforeignkeys

    "Keep Trying"

  • In Enterprise Manager: Right-click on table, All tasks, Display dependencies

    In Query Analyzer: Expand database, User Tables, table, Dependencies

    Also see sp_fkeys in master db.

    Greg

     

    Greg

  • Of course, any of those methods depends on the fact that you have previously defined foreign keys among your tables.

  • You guys are not really from this planet are you? In TOAD for SQL Server (they got at freeware version J) you can see that in the Northwind database the table "Orders" uses the tables "Customers, Employees and Shippers". "Orders" is used by the table "Order Details" . I am looking for the code behind this functionality.

  • First of all you should be bit more civil.

    all those above mentioned methods will show the  table(s) that depend on other tables if proper Fkey relationships are set.

    "Keep Trying"

  • First of all you should be bit more civil.

    all those above mentioned methods will show the  table(s) that depend on other tables if proper Fkey relationships are set.

    "Keep Trying"

Viewing 7 posts - 1 through 6 (of 6 total)

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