On Sep 9, 2011, at 10:27, Glenn Knickerbocker wrote:

> I have a REXX stage that issues several queries to several SQL
> databases.  I want all the results of the first query that produces any
> output.  Since I control the REXX stage, I can add a parameter to tell
> it that, and/or an alternate input to shut off the stream of queries
> using GATE.
>
> Suppose I didn't.  Is there anything I could do downstream to test
> whether SQL has results waiting to go into the pipeline?  I was hoping
> STREAMSTATE might return 0 if it did, but no such luck.
>
I believe I had some of the effect you want with (IIRC)

    callpipe *.input: | take 1 | var V

Input waiting went to V; if no input was available, V was DROPped.
It didn't do what I needed, so I didn't memorize it well.  It may
do what you want.  Procedural Rexx; un-Pipethink.

-- gil

Reply via email to