Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: How to retrieve FOREIGN key information from an ORACLE database using Visual Basic (and preferably ADO/ADOX)
Shared PC wrote in <948976460.19446.0.nnrp-03.c2de9529_at_news.demon.co.uk>...
>Can anyone please give me some guidance as to a way in which it is possible
>to read from an ORACLE database the foreign keys.
ALL_CONSTRAINTS gives you OWNER, CONSTRAINT_NAME, CONSTRAINT_TYPE ('R' means referential), TABLE_NAME (referencing table :: from), R_OWNER (of), R_CONSTRAINT_NAME (name of the unique constraint of the referenced table :: to), DELETE_RULE plus some other information about the constraint ...
ALL_CONS_COLUMNS contains OWNER, CONSTRAINT_NAME, TABLE_NAME, COLUMN_NAME, POSITION (of column in the constraint definition)
analogous you might use the DBA_.... / USER_.... structures -
refer to Chapter 2 - Static Data Dictionary Views of the Oracle Reference Manual for details
hth Received on Thu Jan 27 2000 - 17:51:48 CST
![]() |
![]() |