You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by Erick Erickson <er...@gmail.com> on 2012/03/21 19:43:05 UTC

Re: Breaking up a query results based upon ROWNUM or something similar?

Sure, in Solr you can specify start/rows parameters on queries like:
&start=0&rows=10000
&start=10000&rows=10000
&start=20000&rows=10000

You'll hit the "deep paging" problem, however. Briefly as you page deeper and
deeper you're response time will drop, see:
https://issues.apache.org/jira/browse/SOLR-1726

Best
Erick

On Wed, Mar 21, 2012 at 10:18 AM, Doug Kunzman <dk...@usgs.gov> wrote:
> I'm new to lucene and have searched the archives and FAQ for an answer on
> how to do something and have found no information.
>
> Our server is running SOLR and is running out of memory when returning
> large result sets.
>
> I was curious if anyone there would know how to break up a query so that
> returns only a first the 10000 results, and then the next 10000 results,
> from query that would normally return a 100000?
>
> Something like this in Oracle speech...
>
> select * from
> ( select a.*, ROWNUM rnum from
> ( ) a
> where ROWNUM <= :MAX_ROW_TO_FETCH )
> where rnum >= :MIN_ROW_TO_FETCH;
>
> thanks,
> Doug
>

---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org