Page 1 of 1

DSSEtLimit function

Posted: Mon Sep 19, 2005 3:25 pm
by snassimr
Hi !

I need to run DSSetJobLimit in befor-job subroutine
but the job doesnt stop after 4warnings

Why ?
$INCLUDE DSINCLUDE JOBCONTROL.H



ErrCode = DSSetJobLimit (DSJ.ME, DSJ.LIMITWARN, 4)

Posted: Mon Sep 19, 2005 3:29 pm
by chulett
Because it's too late then. It must be done as part of the process that runs the job, not by the job itself.

Posted: Mon Sep 19, 2005 3:49 pm
by snassimr
So How I can put the command Into job control of Job Sequence ?

Any way to do it without coding the job control mannually ?

Posted: Mon Sep 19, 2005 3:58 pm
by kcbland
A job cannot control itself in any way. Job Sequencer logic is not available for changing. You could cut and paste it into a Batch job, but then you lose the graphical maintenance.

Posted: Mon Sep 19, 2005 4:25 pm
by snassimr
what happend when I set the limit on limits tab during running the job ?

Posted: Mon Sep 19, 2005 8:32 pm
by kcbland
snassimr wrote:what happend when I set the limit on limits tab during running the job ?
That works, but from an un-attended execution you should really consider custom job control.

Posted: Mon Sep 19, 2005 10:07 pm
by ray.wurlod
snassimr wrote:what happend when I set the limit on limits tab during running the job ?
DSSetJobLimit (DSJ.ME, DSJ.LIMITWARN, 4) 8)

But that's not during running the job, that's while making the request to run the job - that is, before the job is running.