system query

  • I need to understand 2 databases and their tables.

    Is there a system query which can help me find out how 'table x of database a is linked to some table of database b'

    I basically want to understand how tables within these databses are related. Which are the primary & foreign key links. The trouble is that foreign and primary key names are not the same across the database. I am in SQL 2000 environment.

    Thanks

  • I believe INFORMATION_SCHEMA views is already existing in sql 2000. You might be able to start from there.

    Happy Coding!!!

    ~~ CK

  • There aren't relationships stored across databases. If someone has data related to something in another database, it's enforced outside of SQL Server.

    The information views are a good place to start, or you could use Enterprise Manager, let it automatically create a database diagram for you and it will show relationships that are defined.

    Moved to SQL 2000 forum.

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

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