cancel
Showing results for 
Search instead for 
Did you mean: 

Schedule background job

Former Member
0 Kudos

There is a background job that currently runs every 1 min.

How can we schedule it to run only from 9am to 6pm everyday?

(Could not find any options in SM36 for that one!)

Any inputs will be highly appreciated.

Thanks

Prasad

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

SAP does not provide such facility. All you can do is.

1) If you want fully automization than, Develop an ABAP program for such restriction and put the program as the 1st step in your job so that job should not run in between 5 PM -9 AM.

2) Othwerwise with some manual intervention, Schedule a new job daily to be started at 9 AM and you can put a condition in the job to not to be run after 6 PM daily and next day you can edit these details for that day.

With Regards,

Saurabh

Former Member
0 Kudos

>

> 1) If you want fully automization than, Develop an ABAP program for such restriction and put the program as the 1st step in your job so that job should not run in between 5 PM -9 AM.

Thanks Saurabh,

I had a hunch this could be done with ABAP....but did not know how to link it to the batch job. Your tip of putting this as the 1st step definitely helped.

Thanks Manu for the link. The last tip in the link helped to validate what Saurabh has mentioned to my customer.

Thanks both you guys.

Regards

Prasad

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi Prasad,

If you donu2019t have ABAP knowledge you can setup your job in order to start after an event.

After that you can get the event triggered from the Operating System:

- log into you Operating System with the SIDadm user id (at the Operating System level) and go to directory /usr/sap/SID/SYS/exe/run

- Run the SAPEVT executable as follows :

sapevt YOUR_EVENT -t pf=/usr/sap/SID/SYS/profile/DEV_DVEBMGS00_server001 nr=01

This will raise the event, and cause the job scheduled within SAP to execute.

In this way you can use the O.S. (u201Ccrontabu201D for example) functionalities in order to schedule your job between 9am to 6pm.

Regards,

Federico Biavati

Former Member
0 Kudos

Thats a good idea too..thanks Federico

Former Member
0 Kudos

Hi,

If you have an external tool for batch scheduling , then you can use that , like TWS or Mercury etc.

Former Member
0 Kudos

Prasad,

Please follow the below steps:

1. Go to SM36 give the job name i.e. ZABC_MYJOB

2. Click on Steps (Upper left corner - 2nd Button) and assign the ABAP report name .i.e. RSUSR002, Check and Save.

3. Click on Start Condition (Upper left corner - Ist Button), click Date/Time and specify the Start Date and Time.

4. Select "Periodic Job" and click on Period values now click on Other Period

5. Now input 1 in the Minute Box. , and check and save.

6. Again Check and Save. and Again Check and Save.

7. Now save the job.

This job will run after every 1 minute.

Thanks

LK

manu_susankar
Active Contributor
0 Kudos

Hi Prasad Kamath,

For more assistence please check the below useful help Doc

[Specifying Automatic Job Repetition|http://help.sap.com/saphelp_nw04/helpdata/EN/c4/3a7fa1505211d189550000e829fbbd/content.htm]

Regards,

S.Manu.

manu_susankar
Active Contributor
0 Kudos

Hi Prasad Kamath,

Job would be in release status... please make the status release to schedule and do the changes as you wish. You can change the status of the job with SM37 > Give your job name select the status released select the status relesed in the next menu you will see the job then menu job>released -> schedule .....

Regards,

S.Manu.