Re: setFetchSize() not working

From: Oliver Jowett <oliver(at)opencloud(dot)com>
To: Jeffrey Tenny <jeffrey(dot)tenny(at)comcast(dot)net>
Cc: postgres jdbc <pgsql-jdbc(at)postgresql(dot)org>
Subject: Re: setFetchSize() not working
Date: 2004-10-10 20:20:10
Message-ID: 4169997A.2060109@opencloud.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Jeffrey Tenny wrote:
> I'm using the 7.3.3 backend, and the JDBC 8.0dev jdbc driver
> (pgdev.306.jdbc3.jar).
>
> I'm calling PreparedStatement.setFetchSize(32), on a table fetching 32KB
> BYTEA records, and I'm blowing out memory on the executeQuery() call
> of the prepared statement.
>
> PreparedStatement.getFetchDirection reports 1000, which is
> ResultSet.FETCH_FORWARD.
>
> Any clues?

Use a newer backend or an older driver. The development driver only
supports cursors when using a V3 protocol connection (supported from 7.4
onwards). You probably want a newer backend anyway even if only the
newest 7.3.x, there are data-loss bugs in earlier 7.3 versions.

There's no real reason that V2 can't use cursors, it's just that the
support has not been reimplemented for the changed protocol layer framework.

In general all the new driver work is happening against 7.4/8.0
backends. We do test for correct behaviour against 7.3 servers, but
there are no guarantees that the driver is going to perform as well.

-O

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Serguei Mokhov 2004-10-10 20:56:57 Re: New jdbc website
Previous Message Kris Jurka 2004-10-10 18:25:09 Re: setFetchSize() not working