禁用外键

select 'alter table '|| t.table_name||' disable constraint '||t.constraint_name||';'   
from user_constraints t where t.constraint_type = 'R'  
order by t.table_name   

 

启用外键

select 'alter table '|| t.table_name ||' enable constraint '||t.constraint_name||';'  
from user_constraints t where t.constraint_type = 'R'  
order by t.table_name  

 

相关文章:

  • 2022-12-23
  • 2021-09-20
  • 2021-11-05
  • 2022-02-03
  • 2021-07-14
  • 2021-11-30
  • 2022-12-23
猜你喜欢
  • 2021-09-24
  • 2022-12-23
  • 2021-07-22
  • 2021-06-04
  • 2021-07-23
相关资源
相似解决方案