db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From geoffrey hendrey <geoff.hend...@gmail.com>
Subject problem with paging performance
Date Sun, 23 May 2010 07:05:02 GMT
I have a table with a BLOB column. I am executing a query in which I do
*not* select the blob. I use Statement.setFetchSize(p) to fetch a "page"
worth of records (typically 10 rows) and Statement.setMaxRows(n*p) to insure
that the result set covers the nth page. I call ResultSet.absolute((n-1)*p)
to position the cursor before the first row of page p. There is a primary
key column on every table that I do this paging with.

This works fine for tables *without* blobs. It's very fast even to put
advance to page 1000. For tables with blobs (typically used to store images
that are several MB each) there is a huge performance hit even though I do
not select the BLOB. Why is this and how can I work around it?

-geoff

-- 
http://nextdb.net - RESTful Relational Database
http://www.nextdb.net/wiki/en/REST

Mime
View raw message