How to view table foreign keys (FKs) in Oracle SQL Developer

This guide will show you how you can view table foreign key constraints in Oracle SQL Developer, free administration and development tool for Oracle.

Foreign keys in Constraints tab

First method is with table Constraints tab (select table and select Constraints tab). Tab lists table constraints - primary, unique and foreign keys and check constraints - all in one grid. Foreign keys are the ones with 'Foreign_Key' value in CONSTRAINT_TYPE column. R_TABLE_NAME holds primary table name.

If you select foreign key, grid under list of constraints holds list of foreign key columns.

Foreign keys in the Designer

Another way to see foreign keys i with table designer. To open designer select table, right click and choose Edit... from context menu.

In the designer dialog select Constraints option. Again, list includes all table constraints and you will distinguish FKs by Type column. After selecting key panel on the bottom displays its details. Schema and Table fields show primary table (blue rectangle), Associations list includes pairs of foreign (Local Column) and primary (Referenced Column) columns.

Comments are only visible when the visitor has consented to statistics cookies. To see and add comments please accept statistics cookies.
0
There are no comments. Click here to write the first comment.