Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Job Scheduling Automatically after Job fails

Former Member
0 Kudos
880

Hi  Folks,

     I am scheduling a job, if the job fails due to some problem at scheduled time is there any option to automate job after sometime automatically.

Thanks in Advance.

Smriti

10 REPLIES 10

Former Member
0 Kudos
536

Hi Smriti,

Regarding Job Scheduling Automatically, I think you need to discuss the same with Basis guys.

Hope they might have some option to do the same.

If you want to perform the same with ABAP, I think you need to use FM likes JOB_OPEN, JOB_SUBMIT and JOB_CLOSE.

SKR

0 Kudos
536

Hi SKR ,

thans for ur quick reply.

   if we are doing it thru ABAP how can we achieve like if Job fails we are writing program to re-run. how we can link our program to re-rn the job automatically.

appreciate your help.

Thanks,

Smriti

0 Kudos
536

Hi Smiriti

The Program for which you are sceduling a job inside it you can check if all work sucessful fine else schedule a new job for the same program.

Please keep in mind job will keep on getting scheduled unless it is sucessful

Nabheet

0 Kudos
536

Hi Nabheet,

   Thanks for your reply.

    how can we schedule a new job for the same program inside the program how we can achieve this.

could you please explain clearly how can we schedule a job  for the same program from our program.

Thanks,

Smriti

0 Kudos
536

Lets say i have a program ZPR1. Inside it i check if work is not done set GV_RESCHEDULE flag as X.

Then at the end check if flag is X then use SUBMIT ZPR1 between JOB_OPEN and JOB_CLOSE function module.

Please keep in mind it should not go into an infinite loop

Nabheet

Former Member
0 Kudos
536

Hi Smriti ,

Yes, it is possible .
You will have to create an event for the same as soon as the job will fail it will trigger that event which will schedule the job again .
But first you have to be sure about rescheduling , as that job got failed due to some reason & re-scheduling it without analyzing will not give different result .

Thanks,

Nash

Former Member
0 Kudos
536

Hi Smriti ,

Yes, it is possible .
You will have to create an event for the same as soon as the job will fail it will trigger that event which will schedule the job again .
But first you have to be sure about rescheduling , as that job got failed due to some reason & re-scheduling it without analyzing will not give different result .

Thanks,

Nash

Former Member
0 Kudos
536

Hi Smriti ,

Yes, it is possible .
You will have to create an event for the same as soon as the job will fail it will trigger that event which will schedule the job again .
But first you have to be sure about rescheduling , as that job got failed due to some reason & re-scheduling it without analyzing will not give different result .

Thanks,

Nash

Former Member
0 Kudos
536

Hi Smriti ,

Yes, it is possible .

You will have to create an event for the same as soon as the job will fail it will trigger that event which will schedule the job again .

But first you have to be sure about rescheduling , as that job got failed due to some reason & re-scheduling it without analyzing will not give different result .

Thanks,

Nash

0 Kudos
536

Hi Nash,

  how can i create an event for job fail and how it reschedules the job, could you please elobrate.

appreciate your help.

Thanks,

Smriti