Suspending and restarting batch jobs
I need to have an easy way for our Unix Admins to be able to suspend and then restart batch jobs. I can use a menu based script that will allow them to suspend the jobs. This fires an event that then triggers a batch job that runs BTCTRNS1. I then cannot, but would like to, have another event that runs BTCTRNS2 because that job is also suspended. These reports also do not support variants.
Is there something that I could use that would suspend all except for a selected job?
Or, is there something I could put in step 2 of the suspend job that would unsuspend the unsuspend (BTCTRNS2) job?
Jobs are stored in tables TBTCO, TBTCS, TBTCP and TBTCEVTJOB. Their fields are well explained in the SAP data dictionary (transaction SE11). In previous projects, I wrote scripts which fiddle in those tables directly (using SQL on database level) to postpone, delete or un-schedule background jobs.
For you administrators, you could write SQL scripts which update those tables directly. You might as well write ABAP reports which modify these tables from within the SAP system. You can then use SAP events to call up on these ABAP reports from a menu-based Unix script.
This was first published in July 2006