HP3000-L Archives

February 2002, Week 3

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:
Neil Harvey <[log in to unmask]>
Reply To:
Neil Harvey <[log in to unmask]>
Date:
Sat, 16 Feb 2002 08:52:04 +0200
Content-Type:
text/plain
Parts/Attachments:
text/plain (92 lines)
You can tack the MPEX SEARCH command onto the PRINTO statement.
And by examining the MPEXPRINTLINESFOUND variable, you can determine if the
string you searched for was found, or not.

Hope this helps

Neil


From the MPEX %HELP PRINTO (hope I'm not violating any copywrite
rules....):-

(CHG) %PRINTI, %PRINTO


Syntax:   %PRINTI [ #Ispoolfilenumber ]   [;mpexprintparms]
                  [ #Jjobnumber        ]
                  [   jobname         ]
                  [ #Aschedjobnumber  ]

          %PRINTO [{#Ospoolfilenumber|#Jjobnumber|jobname}]
          [;mpexprintparms]
          [;IFLOW]                                         (NEW)
          [;SEARCH={IFTRUE|IFFALSE}]                       (NEW)

Examples: %PRINTI #J1234; SEARCH=":"
          %PRINTO MYJOB,MYUSER.MYACCT; PAGE=9999; NUM
          %PRINTO #O1234; SEARCH="CIERR" or "FSERR"; CONTEXT=-2
          %PRINTO ;WAIT;IFLOW

The %PRINTI and %PRINTO commands print, respectively, input and output
spoolfiles; you may, optionally specify any of the parameters of the %PRINT
command (see above).

If you specify a spoolfile number ("#I1234" for %PRINTI, "#O1234" for
%PRINTO),
the given spoolfile will be printed.

If you specify a job number or job name, MPEX will find and print the $STDIN
(for %PRINTI) or $STDLIST (for %PRINTO) spool file of the given job.

If you don't specify either a job number, job name or spoolfile number, the
$STDIN or $STDLIST spoolfile of the last job submitted by MPEX (via
%$command,
%SUBMIT or %SCHEDULE) or by STREAMX (see the SECURITY User Manual) or by
VEAUDIT will be printed.

%PRINTI also works on all input spool files (which, however, exist only for
currently running jobs, waiting jobs, and scheduled jobs, not jobs that have
already run), but requires SM capability.


USING ;WAIT, ;IFLOW, & ;SEARCH=...TO VIEW $STDLISTs

On MPE/iX, %PRINTO works on all output spool files, including ones currently
being generated by a running job.  There are a few %PRINT keywords that are
especially well suited for printing $STDLIST files.  The ;WAIT= keyword has
already been documented under the %PRINT command since it will work for any
output file, not just $STDLISTs.

When you supply the ;IFLOW keyword, %PRINTO will display the FALSE portions
of
:IF/:ELSE/:ENDIF blocks in low intensity.  This makes it easier to scan the
output of a $STDLIST file since you can tell at a glance that a particular
statement was or was not executed without having to look back (perhaps
several
screens) for the "*** CONDITION FALSE, COMMANDS IGNORED..." message buried
in
the $STDLIST.

The ;SEARCH= attribute IFTRUE takes the above concept a step further and
allows
you to filter out the false portion of a job stream entirely.  Or, if you
prefer, you can use ;SEARCH=IFFALSE to just view the parts of a job that
were
not executed.  In either case, if something appears in the listing that
should
not have, then it is a simple matter to look back at the preceding condition
to
determine why it was not evaluated correctly.



If you're interested, the %PRINT command sets a variable called
MPEXPRINTLINESFOUND to the number of lines that actually contain the given
search string.  (If no ;SEARCH=...parameter is specified,
MPEXPRINTLINESFOUND
is set to the total number of lines in the files printed.)

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

ATOM RSS1 RSS2