select fk_col.constraint_name, fk_col.table_name, fk_col.column_name
from user_constraints pk, user_constraints fk, user_cons_columns fk_col
where pk.table_name = ‘TEST‘
and pk.constraint_type = ‘P‘
and fk.r_constraint_name = pk.constraint_name
and fk_col.constraint_name = fk.constraint_name
order by 2, 3;
查找某个表被哪些表引用。外键
时间: 2024-10-09 23:57:20