Subject Re: [firebird-support] intermediate messages from a query
Author Helen Borrie
At 10:42 AM 12/09/2003 +0200, Martijn wrote:

> > >
> > >Shouldn't this procedure start returning before the complete procedure
> > >is finished because of the SUSPEND?
> >
> > Well...yes...it will output that row then recommence /* whatever */ in the
> > next line, work through to the end of the loop and then go through the
>loop
> > again. But it will keep looping like that until it is all done.
>
>ok - then we agree. By using SUSPEND this way, you can do a bit of
>a progress callback to the client - that is, if you use SELECT to execute
>it :-)

No, AFAIK. That would require that the rows be released from the server
one by by one, rather than either being released as the output of the
successfully completed SP or being erased altogether in the case that it
abends...for atomicity, it shouldn't produce a "partial success". It
should either totally succeed or totally fail.

A way you could test that would be to hook up a TIB_Cursor to a SELECT
procedure that works like the posted example, build an exception into one
of the rows it has to process in the for...select loop and see whether you
get any rows back in the TIB_Cursor. You could do it in fact in the Cursor
window of IB_SQL, couldn't you?

heLen