DBMS_IJOB BROKEN

Published by Patrizia Gardis on

With the article DBMS_IJOB BROKEN, we provide a statement that allows blocking the normal scheduling of a specific JOB.

When a scheduled JOB in the Oracle database encounters a failure, the JOB is rerun after 1 minute. If it fails again, it is run after 2 minutes. If it fails again, it is run again after 4 minutes and so on, until the sixteenth attempt, which ends this cycle and puts the JOB in the BROKEN state.

It may happen that for some reason the scheduling of a specific Oracle JOB needs to be blocked, either at the client's request or for a particular activity.

So, we have 2 possibilities. Either we set the JOB to broken with the DBMS_IJOB BROKEN package, or if there are many JOBS, we can set the JOB_QUEUE_PROCESSES parameter to 0 in order to disable the automatic start of the JOBS. This parameter can be modified dynamically and executed as follows:

alter systems set job_queue_processes=0 scope=both;

 

Instead, in the case where we need to disable the start of a single JOB, in the article, we provide a DBMS_IJOB Broken, which will allow you to block the normal scheduling of a JOB.

Furthermore, the dbms_ijob package, unlike the dbms_job package, allows you to remove the JOB belonging to another user.

exec dbms_ijob.broken (&JOB,TRUE);

To view my guides on CRS command click here!
A questo LINK, invece, troverai le query SQL

Stay updated on our activities by joining our community:
Facebook
Youtube
Linkedin

 

 


0 Comments

Leave a Reply

Avatar placeholder