Why don't you use $zf(-1 with the output piped to the null device?
Mark

"Paul Bradney" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Hi,
>
> We are currently porting some systems from MSM to Cach� and have come
across
> a slight quandary
>
> In MSM, we had 3 ways of calling host commands on the OS
>
> $$TERMINAL^%HOSTCMD - Foreground job (i.e. current job waited until it
> finished), displayed I/O, couldn't be used in JOBbed routine
> $$JOB^%HOSTCMD - Like TERMINAL except OK in JOBbed routine, but if run in
> foreground, current job waited until it completed, no I/O displayed
> $$JOBWAIT^%HOSTCMD - Spawned as background job regardless of whether run
in
> foreground or background. No I/O displayed (obviously)
>
> So if you wanted to (for example), pass the Unix username into a file and
> then read the file back in, you would use either TERMINAL or JOBWAIT (if
in
> a background job) to do the work, as it was necessary to wait for the
first
> command to finish before you did the second.
>
> If you just wanted to start a process running in Unix without waiting you
> would use the $$JOB function.
>
> Now in Cache you get $ZF(-1 and $ZF(-2
>
> As I've seen it after testing $ZF(-1 emulates $$TERMINAL and $ZF(-2
emulates
> $$JOB. What I need is one that emulates $$JOBWAIT. I don't want to use
> $ZF(-1 because it returns I/O (if there is any) but I want to wait for the
> command to complete. $ZF(-2 on the other hand doesn't do any I/O but also
> returns before the spawned OS command has finished.
>
> Any ideas?
>
>



Reply via email to