Subject | RE: [Firebird-Java] GDS Exception: Cursor unknown |
---|---|
Author | Rick DeBay |
Post date | 2004-07-27T19:51:29Z |
Thanks for the explanation (ignore my next email, which crossed this
one).
If I need to commit while going through a ResultSet, I'll use two
connections and set the transaction isolation to whatever is
appropriate.
Would it be valid to set the fetch size to 103,000 (ignoring issues of
client memory usage, network, etc) to work around this?
-----Original Message-----
From: Roman Rokytskyy [mailto:rrokytskyy@...]
Sent: Tuesday, July 27, 2004 3:45 PM
To: Firebird-Java@yahoogroups.com
Subject: Re: [Firebird-Java] GDS Exception: Cursor unknown
DatabaseMetaData.supportsOpenCursorsAccrossCommit() result. This is
related
to the result set holdability, which is not supported by the server.
In theory driver could close result sets during commit, maybe this will
be
added in next versions.
Do not commit when traversing result sets. If you relly need to commit,
you
can execute "COMMIT RETAIN" SQL statement, however there might be issues
when using this statement. Ask in Firebird-Support, they can explain
better.
after
1198-th record. There is no rule, everything depends on the record size,
how
many records fit the network packet. This is very protocol specific
issue.
Roman
Yahoo! Groups Links
one).
If I need to commit while going through a ResultSet, I'll use two
connections and set the transaction isolation to whatever is
appropriate.
Would it be valid to set the fetch size to 103,000 (ignoring issues of
client memory usage, network, etc) to work around this?
-----Original Message-----
From: Roman Rokytskyy [mailto:rrokytskyy@...]
Sent: Tuesday, July 27, 2004 3:45 PM
To: Firebird-Java@yahoogroups.com
Subject: Re: [Firebird-Java] GDS Exception: Cursor unknown
> I have a select that returns 102903 rows. I then loop through theseCommit closes the server-side cursor, see
> batching two sets of PreparedStatements, and execute and commit
> every 1000.
DatabaseMetaData.supportsOpenCursorsAccrossCommit() result. This is
related
to the result set holdability, which is not supported by the server.
In theory driver could close result sets during commit, maybe this will
be
added in next versions.
Do not commit when traversing result sets. If you relly need to commit,
you
can execute "COMMIT RETAIN" SQL statement, however there might be issues
when using this statement. Ask in Firebird-Support, they can explain
better.
> When calling rs.next() for record 1199 I get the following exception:You get this exception during the next fetch, in your case it happened
after
1198-th record. There is no rule, everything depends on the record size,
how
many records fit the network packet. This is very protocol specific
issue.
Roman
Yahoo! Groups Links