Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Help with Dictionary Views: confirming FK relationship

Help with Dictionary Views: confirming FK relationship

From: BD <bobby_dread_at_hotmail.com>
Date: 1 May 2006 14:27:29 -0700
Message-ID: <1146518848.333662.23730@i40g2000cwc.googlegroups.com>


Hi, all.

I'm on 8.1.7.4 on AIX.

I have a task to identify tables in my database that lack two specific columns (figured that one out), and which lack a FK relationship to any tables that have those columns.

In any "sane" FK relationship, the column names on both sides of the relationship will be the same, so the first query would be all I would need. But, strictly speaking, it is not mandatory. I could have an FK relationship from TABLE1.COLUMN1 to TABLE2.SPUD if I wanted to.

So I need to find out which tables have columns A and B, and which tables have any FK relationships against those tables, on columns A and B.

dba_constraints and dba_cons_columns will tell me about the 'child' side of the FK relationship, but I need to confirm the 'parent' side of the FK relationship; I don't see a sys view which indicates _both_ sides of the relationship.

Does this information exist anywhere in the dictionary views?

Thanks,

BD Received on Mon May 01 2006 - 16:27:29 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US