Subject Error destroy everything
Author Dimitry Sibiryakov
On 1 Mar 2002 at 12:47, Paul Reeves wrote:

> > Connect and start transaction are omitted.
> > isc_dsql_prepare() - OK
> > isc_dsql_execute() - OK
> > isc_dsql_fetch() - OK
> > isc_dsql_execute() - Error "Attempt to reopen an open
> > cursor". OK, ignore.
>
> It has been a while since I did any api level programming, but I would
> have thought that it may be an idea to close the cursor before
> re-executing.

Yes, sure, cursor must be closed. I know it. But I tested
IB's behavior, because the documentation doesn't provide
the answer: what'd happened to cursor after error. Would be
the old cursor still opened? New one? Both closed and stmt
handle is invalid? Now I know the answer - AV and hang up
on the next operation. :(

> Has this worked in previous builds or is this the first time you have
> tried this?

It's my first experience with IB API. I put a few buttons
onto a form, named them "Start trans", "Prepare", "Exec"
and so on, wrote the appropriate code and started to press
them in different orders. Got a bundle of "right" errors,
found a couple of interesting things (as an example: a
prepared statement lives longer than the transaction) and this
strange behavior.

SY, Dimitry Sibiryakov.