From: Oliver Jowett <oliver@opencloud.com>
To: Clemens Eisserer <linuxhippy@gmail.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: NullPointerException when calling ResultSet.absolute(int)
Date: Tue, 30 Aug 2005 10:23:56 +1200
Message-ID: <43138AFC.20305@opencloud.com> (raw)
In-Reply-To: <194f625505082904281f3ca75@mail.gmail.com>
References: <194f625505082810015456609c@mail.gmail.com>
<43122F3E.3040002@opencloud.com>
<194f625505082904281f3ca75@mail.gmail.com>
Clemens Eisserer wrote:
> Hello Oliver and thanks a lot for answering,
>
>
>>Either you can use two queries, or use a scrollable ResultSet and call
>>ResultSet.last() / ResultSet.getRow(). The second approach causes the
>>entire ResultSet to be loaded into the Java heap, though, so it's not so
>>good for large results.
>
> Currently I use the last()/getRow approach but as you confirmed this
> approach does exactly what I don't want - to transfer the whole
> selection between server and client.
> Isn't there a workarround for this, maybe setting the fetch-size
> (default set to 0)?
Not with the current driver -- using a scrollable resultset disables use
of cursors, so the fetchsize is ignored.
-O
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-jdbc@postgresql.org
Cc: oliver@opencloud.com, linuxhippy@gmail.com
Subject: Re: NullPointerException when calling ResultSet.absolute(int)
In-Reply-To: <43138AFC.20305@opencloud.com>
References: <194f625505082810015456609c@mail.gmail.com> <43122F3E.3040002@opencloud.com> <194f625505082904281f3ca75@mail.gmail.com> <43138AFC.20305@opencloud.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox