On Sep 10, 11:44*am, norm.raph...@metso.com wrote:
> Nothing yet explains why it works sometimes and fails other times.
Perhaps because the log file isn't flushed completely to disk?
This is a discussion on Re: Pipe search of command procedure log file containing pipe search command. command. command. - VMS ; FrankS wrote on 09/10/2008 10:25:54 AM: > On Sep 10, 9:40 am, norm.raph...@metso.com wrote: > > Is there a better way to do this? > > Why not just check the status condition after each CONVERT completes? When the IF-STATEMENT ...
FrankSwrote on 09/10/2008 10:25:54 AM:
> On Sep 10, 9:40 am, norm.raph...@metso.com wrote:
> > Is there a better way to do this?
>
> Why not just check the status condition after each CONVERT completes?
When the IF-STATEMENT finds a dup, it takes all the collected error
lines and e-mails them. Constructing something to store all that
would be far more complex and/or require an output temporary file,
which is what the pipe search is employed to eliminate. I don't want
just to know if there were dups, but to e-mail them.
The case here is/was somewhat simplified to uncomplicate it.
Nothing yet explains why it works sometimes and fails other times.
>
> $ SET NoON
> $ CVT_DUP = %X
> $ DUP_OCCURS = 0
> $
> $ CONVERT
> $ IF ($STATUS .EQ. CVT_DUP) THEN GOSUB RECORD_OCCURANCE
> $ IF (.NOT. $STATUS) THEN GOTO KABOOM
> $
> $ CONVERT
> $ IF ($STATUS .EQ. CVT_DUP) THEN GOSUB RECORD_OCCURANCE
> $ IF (.NOT. $STATUS) THEN GOTO KABOOM
> $
> .
> . Repeat however many $CONVERTs you need
> .
> $
> $ IF (DUP_OCCURS .NE. 0)
> $ THEN
> $
> $ ENDIF
> $ EXIT
> $
> $ KABOOM:
> $
> $ EXIT
> $
> $ RECORD_OCCURANCE:
> $ DUP_OCCURS = DUP_OCCURS + 1
> $ RETURN
> $
On Sep 10, 11:44*am, norm.raph...@metso.com wrote:
> Nothing yet explains why it works sometimes and fails other times.
Perhaps because the log file isn't flushed completely to disk?