On Mon, 2009-11-02 at 19:49 -0500, Paul Tomblin wrote:
> Here's what I'm thinking
>
> final static int MAX_ROWS = 100;
> int start = 0;
> query.setRows(MAX_ROWS);
> while (true)
> {
> QueryResponse resp = solrChunkServer.query(query);
> SolrDocumentList docs = resp.getResults();
> if (docs.size() == 0)
> break;
> ....
> start += MAX_ROWS;
> query.setStart(start);
> } Why not after the first limited fetch read how many hits there are and on the second fetch get all remaining documents. Example code (see the do-while loop) http://sesat.no/projects/sesat-kernel/xref/no/sesat/search/query/token/SolrTokenEvaluator.html#237 ~mck -- "This above all: to thine own self be true. It must follow that you cannot then be false to any man." Shakespeare | semb.wever.org | sesat.no | finn.no |
signature.asc
Description: This is a digitally signed message part
