Re: ODBC application getting error 01002 on SQLFetch of 11th row

From: Mark E. Hansen <meh_at_NOSPAMunify.com>
Date: Wed, 29 Nov 2000 16:00:05 -0800
Message-ID: <3A259885.6142DF9_at_NOSPAMunify.com>


Sybrand Bakker wrote:
>
> Ora-1002 is usually caused by commits inside FETCH loops.
> Somehow you are doing something (DDL?) causing Oracle to commit.
> Committing manually will only aggravate the problem, instead of resolving
> it.
> There is no internal limit, just don't commit inside your loop.

Thanks for the quick response. The simple case that still shows this problem [Quoted] does nothing inside the loop but increment a counter.

Can you think of any other reason why this would happen?

>
> Hth,
>
> Sybrand Bakker, Oracle DBA
>
> "Mark E. Hansen" <meh_at_NOSPAMunify.com> wrote in message
> news:3A2584C4.106733D0_at_NOSPAMunify.com...
> > I hope someone can help...
> >
> > I have an ODBC application running on Windows/NT 4, sp/4 and have a
> > server running on RedHat Linux version 7. The Oracle release in both
> > cases is 8iR2.
> >
> > When I do a select from a table and include a "for update" in the
 statement,
> > then I get an error from SQLFetch on the 11th row:
> >
> > ORA-01002: fetch out of sequence
> >
> > I tried a commit after the 10th row, with:
> >
> > SQLEndTran(SQL_HANDLE_DBC, hdbc, SQL_COMMIT)
> >
> > but this didn't help.
> >
> > Can anyone tell me what I need to do to prevent this error and get
> > through the entire result set?
> >
> > Am I hitting a limit on some buffer that I can increase?
> >
> > Thanks,
Received on Thu Nov 30 2000 - 01:00:05 CET

Original text of this message