Re: Server side resultset search (for performance reasons)

From: Nic <nferrier(at)tapsellferrier(dot)co(dot)uk>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Jesus Sandoval <meli(at)mzt(dot)megared(dot)net(dot)mx>, pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Server side resultset search (for performance reasons)
Date: 2003-08-04 14:15:51
Message-ID: 87u18xa4q0.fsf@tapsellferrier.co.uk
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> writes:

> >> The application is returning 300,000 records in some SELECT clause (a
> >> ResultSet) this finish the client's JVM memory, so my solution to this
> >> was to use the SELECT's LIMIT clause returning 600 records and making
> >> the internal logic that when the user gets past the 600th record the
> >> application automatically issues another query with LIMIT and OFFSET
> >> clauses causing a little delay but this is better than finishing the
> >> memory in the client's machine (if you know a better solution or have
> >> some advices, please let me know).
>
> I'm surprised no one has yet suggested using a cursor.

Which the JDBC driver in CVS now supports.

--
Nic Ferrier
http://www.tapsellferrier.co.uk

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Felipe Schnack 2003-08-04 14:16:41 Re: java object store
Previous Message Tom Lane 2003-08-04 14:05:40 Re: Server side resultset search (for performance reasons)