Re: very large result sets and ResultSet.relative() to jump to a desired offset - Mailing list pgsql-jdbc

From Matt Magoffin
Subject Re: very large result sets and ResultSet.relative() to jump to a desired offset
Date
Msg-id 54375.192.168.1.106.1222297305.squirrel@msqr.us
Whole thread Raw
In response to Re: very large result sets and ResultSet.relative() to jump to a desired offset  (Kris Jurka <books@ejurka.com>)
List pgsql-jdbc
> A patch was posted here that almost worked, but never quite got there.
>
> http://archives.postgresql.org/pgsql-jdbc/2004-05/threads.php#00004
>
> For the 8.0 release, how server side cursors work was completely
> rewritten, so that patch isn't terribly relevent anymore.  The patch was
> based on the fact that server side cursors were implemented by the driver
> issuing explicit SQL level DECLARE CURSOR commands and could easily be
> extended to add a SCROLL option and could then move around in it by
> issuing more SQL commands to fetch the data it wanted.  With the 8.0
> release we no longer do anything like that at the SQL level and do it
> entirely at the protocol level.  Unfortunately the protocol level "portal"
> which is equivalent to a cursor does not allow you to specify the
> scrollable attribute or let you do anything other than retrieve results
> going forward.
>
> The JDBC team is hoping that the next protocol version will contain
> support for more portal control and navigation features so that scrollable
> resultsets can be cleanly built upon the existing structure.  Who knows
> when that protocol change might happen though...
>
> Perhaps it is possible to adapt the original patch without throwing away
> all of the work to use portals, but it's not something I've investigated.
>
> Kris Jurka

Yes, that was the thread I spotted before, thanks for finding that. It's a
bummer that the current protocol won't cleanly support scrollable result
sets! I'd be glad to help out in any way possible for this feature... even
if it's just testing.

-- m@

pgsql-jdbc by date:

Previous
From: Kris Jurka
Date:
Subject: Re: very large result sets and ResultSet.relative() to jump to a desired offset
Next
From: Oliver Jowett
Date:
Subject: Re: very large result sets and ResultSet.relative() to jump to a desired offset