I am not a programmer, but can cobble simple cl programs together. I have a
couple of batch jobs that sometimes go into a lckw status, which holds
everything else up (its unavoidable). Is there some simple program I can
write in CL to monitor for this, and in the event of, send a message to
qsysopr msgq (i could then pick this up and use an application we have to
send me a text message)? I'm running v4r4.
Many thanks in advance
On Sat, 19 Jun 2004 00:13:38 +0100, "Truffle" <tru...@nospam.com>
wrote:
You could use the QUSLJOB API to get a list of jobs that you want to
monitor. Use format JOBL0200 and request key 0101 (active job
status). Loop through the user space looking for jobs with an active
job status of LCKW. SNDPGMMSG your message to QSYSOPR for each one
found (or collect a count and send one message to QSYSOPR or whatever
suits your need).
Repeat this process using a DLYJOB to wait between checks.
--
Ken
http://www.ke9nr.net/
Opinions expressed are my own and do not necessarily represent the views of my employer or anyone in their right mind.
I suggest you do a little research on monitoring a message queue. The
CLP could watch for the record lock message and then call a program to
send the message on.
Try seraching www.seach400.com in addition to this group.
Hope it helps.
Dan
On 22 Jun 2004 15:39:39 -0700, dann...@cox.net (QMAGIC) wrote:
>I suggest you do a little research on monitoring a message queue. The
>CLP could watch for the record lock message and then call a program to
>send the message on.
Two problems with your suggestion:
1. You replied to me rather than to the original poster.
2. There will be no message to a message queue until the LCKW ends,
which could be seconds, minutes, hours, or even never [a record lock
with WAITRCD(*NOMAX)].
"QMAGIC" <dann...@cox.net> wrote in message
news:b2431aa9.04062...@posting.google.com...
"Truffle" <tru...@nospam.com> wrote in message
news:40e46dbb$0$28265$cc9e...@news-text.dial.pipex.com...