lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matt Quail <>
Subject Re: Iterating TermEnum backwards
Date Thu, 26 Feb 2004 21:46:14 GMT
>> I know I could "invert" my dates (something like MAX_LONG - date) to get
>> the REVERSE order, but I want to be able to do "least recent" and "most
>> recent".
> Why not have two date fields, one inverted and one not?
>> PS: my current solution is to do a binary search between MIN and MAX,
>> halving my search space until I find close to N matching documents.
> That doesn't sound like a bad solution.

Cool, thanks for all your suggestions. I'm getting adequate performance 
from my binary search now, and if it really becomes a performance 
problem, I'll just index an inverted version of the date (we all have 
diskspace to spare!).


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message