Toon de foreign-key’s en de betrokken wederzijdse tabellen, kolommen en constraints

on
SELECT LOWER(cons1.constraint_name) constraint_name
,      LOWER(cons1.table_name||'.'||conc1.column_name) tab_column
--,      conc1.position
,      LOWER(cons2.table_name||'.'||conc2.column_name||'   ('||cons2.constraint_name||')')  r_tab_column
--,      conc2.position
FROM   all_constraints  cons1
 JOIN  all_cons_columns conc1
   ON  cons1.constraint_name = conc1.constraint_name
  AND  cons1.owner           = conc1.owner
 JOIN  all_constraints  cons2
   ON  cons2.constraint_name = cons1.r_constraint_name
  AND  cons2.owner           = cons1.owner
 JOIN  all_cons_columns conc2
   ON  conc2.constraint_name = cons2.constraint_name
  AND  conc2.position        = conc1.position
  AND  conc2.owner           = cons2.owner
WHERE  cons1.owner           = '<OWNER>'
AND    cons1.constraint_type = 'R'
ORDER  BY cons1.table_name
,         conc1.position