DECLARE BEGIN /* Modify this query for whatever jobs you want to suspend, e.g. job_name like 'RMAN_%', or job_name like 'BACLUP%' */ FOR jguid IN (SELECT job_id FROM mgmt_job WHERE job_name like 'BACKUP_%' AND job_owner = 'SYSMAN' AND parent_job_id is null AND is_library = 0) LOOP BEGIN -- to suspend JOB mgmt_job_engine.suspend_job(jguid.job_id); -- to resume JOB mgmt_job_engine.resume_job (jguid.job_id); dbms_output.put_line(jguid.job_id); END; END LOOP; END; / * see mgmt_job_engine package for more options and details.
Blog com dicas, scripts, How-to para DBA´s e Desenvolvedores ORACLE.