April 8, 2010 at 6:06 am
Hey Paul, that query is really great. I can use that.
I am going to modify it a bit to also allow one to give the column name, and list all tables that the column is in.
for example, if I list "AttributeID" as a PriMary Key column in the Attribute table, I want to know all other tables that "AttributeID" is in. I think that I can get that from parts of the query that you gave me.
I am trying to learn a database that has a lot of tables, well over 2500, and that was not designed correctly at all. So things are all weird. With this type of query, I can find all the tables that have a foreign key column, that will help me in finding those table names. Then in Erwin, I can simply use the find feature, and it will take me to the table in the diagram.
That is what I am wanting to see in the query as well.
Thank you for all your work on this. I really appreciate it.
Andrew SQLDBA
April 8, 2010 at 6:46 am
You're welcome, Andrew. Thanks again for the poster 😎
April 9, 2010 at 11:33 am
April 9, 2010 at 9:51 pm
gsej.sql (4/9/2010)
Here's one:http://www.sqlmag.com/article/sql-server/sql-server-2005-system-diagram.aspx
GSEJ
That's a subscription site (luckily I am a subscriber) and the link therein takes you to the same link posted previously by Andrew 🙂
Viewing 4 posts - 16 through 18 (of 18 total)
You must be logged in to reply to this topic. Login to reply