HP3000-L Archives

August 1999, Week 2

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
"Johnson, Tracy" <[log in to unmask]>
Reply To:
Johnson, Tracy
Date:
Mon, 9 Aug 1999 20:30:48 +0100
Content-Type:
text/plain
Parts/Attachments:
text/plain (31 lines)
> From:   Jeff Keepers [SMTP:[log in to unmask]]
>
> All MPEX guru's hear my plea:
>
> I am writing pre-process MPEX commands for a job that
> will run in batch.
> The job can be run multiple times by the end user but
> two requests can't run at the same time.  I was looking for a MPEX
> command/variable that would let me look and see if the job is
> currently running.
> There is the SHOWJOB command, but it doesn't return a variable
> that I can check.  I can write code that will set my own flags, but > I thought there was a way to do this using MPEX
> commands.  Any assistance would be most appreciated.

We do this all the time.  One use we make of it is to wait until a certain job finishes before starting another.  (Note the JOBNAME parameter must needs be within double quotes, i.e.:)

XEQ WAITFOR.COMMAND.SYS "'MYJOB,OPERATOR.SYS'"


PRINT OF COMMAND FILE FOLLOWS:

USER DEFINED COMMAND FILE:  WAITFOR.COMMAND.SYS

PARM JOBNAME
SETVAR JSC 1
WHILE JSC>0
  PAUSE 60
  SHOWTIME
  MAIN.PUB.VESOFT;INFO="SETVAR JSC JSCOUNT(!JOBNAME)"
ENDWHILE

ATOM RSS1 RSS2