-- This script will create a SQL script to disable any database constraints in the current schema.
-- Mark Reineck 12-22-1997
set feedback off
set head off
set echo off
-- Write the script to a file, otherwise it is useless
spool disconst.sql
-- Create the enable constraint sql statements
select 'alter table ' || owner || '.' || table_name || ' enable constraint ' || constraint_name || ';' from user_constraints order by constraint_type desc;
spool off;
-- Reset some stuff
set feedback on
set head on
set echo on