經過 user_constraints表查詢,constraint_type: P(主鍵),R(外鍵),C(約束)code
select a.constraint_name,a.constraint_type,b.column_name,a.table_name from user_constraints a,user_cons_columns b where a.table_name=b.table_name and a.owner='SJ_BUZMGT' and b.constraint_name like '%FK_NT%';