home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!olivea!gossip.pyramid.com!pyramid!infmx!davek
- From: davek@informix.com (David Kosenko)
- Newsgroups: comp.databases.informix
- Subject: Re: ESQL C problem with sqlerrd[2]
- Message-ID: <1992Dec17.172150.328@informix.com>
- Date: 17 Dec 92 17:21:50 GMT
- References: <1giuitINNcgq@emory.mathcs.emory.edu>
- Sender: news@informix.com (Usenet News)
- Organization: Informix Software, Inc.
- Lines: 24
-
- Kristen Altman writes:
- >In my application, I am using ESQL C 4.1 and formatting
- >dynamic SQL statements.
- >
- >I have found the following problem/possible bug:
- >
- >After the first fetch the number of rows returned in sqlerrd[2]
- >is 0, but the sqlca.sqlcode = 0 also. If I understand this correctly,
- >the sqlerrd[2] says there are no rows, but the sqlcode says there are rows.
-
-
- When fetching data with a cursor, sqlerrd[2] will not be set until the
- last bufferfull of rows are selected into by the server (primarily because
- you can't know how many rows there will be until that point). To put
- it more simply, on selects with cursors, do not expect sqlerrd[2] to be
- filled in until the last row has been fetched (there are ways around
- this, such as using a scroll cursor and fetching last).
-
- Dave
- --
- Disclaimer: These opinions are not those of Informix Software, Inc.
- **************************************************************************
- "I look back with some satisfaction on what an idiot I was when I was 25,
- but when I do that, I'm assuming I'm no longer an idiot." - Andy Rooney
-