We have a job that is run every weeknight to handle our batch updates (i.e. PA100, BN100) in a job queue dedicated for that purpose. When we are running payroll, we do not want these jobs to process, so we manually put the job queue on “hold” and then release it after payroll is finished. Unfortunately, we occasionally forget to put the queue on hold. Is there any way to programmatically schedule the “hold” on the queue so we could, say, schedule the “hold” to start on Monday August 21st and release on Wednesday August 23rd. That way we could set up our schedule for the coming year.
The only way I have been able to accomplish this is with a custom script. Here is what I do (although you could also use cron)
I write a Perl script that has all the logic I need and at some point in the script I make a call to jqsubmit to run the job,
Then I define a token to run the script
then I define a job to run the token
then I do a recdef to run the job.
So when the job runs the script determines if it should really run the job or not.
Why do I go through all this? Well clients like having recdef out there and the script is nice cause I can create nice log files, xml output whatever I need.
I hope that helps. I wrote a little step by step guide for dummies on doing this whole tokendef/jobdef/recdef thing if you want I can send it to you. Not that you're a dummy. :)
Tan