lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From houyang <hui.ouy...@oracle.com>
Subject RE: How to search between dates?
Date Sun, 04 Sep 2005 17:00:17 GMT
"YYYYMMDD" is better since it has less number unique terms compared with the unix time stamp
if you only care about the days.

-----Original Message-----
From: Filip Anselm [mailto:filip@nable.dk] 
Sent: Sunday, September 04, 2005 3:56 AM
To: java-user@lucene.apache.org
Subject: Re: How to search between dates?

DateFilter sounds great!! - But how is the best way to store dates in af
Field? I get the time as a unix time stamp, seconds since epoch - and
usually I can cut it down to hours or days since ephoc instead - if this
has any effect on the perfomance...

thanks...

Chris Hostetter wrote:

>: How do I combine two queries - one made by the QueryParser and the
>: programmatically made RangeQuery?
>
>you could make them both children of a single BooleanQuery, but as long as
>you're going to write a little java code to put them together -- why not
>use a DateFilter instead?
>
>http://lucene.apache.org/java/docs/api/org/apache/lucene/search/DateFilter.html
>
>...it's more efficient then a RangeQuery, it doesn't have the same
>"TooManyCLauses" limitations as a RangeQuery, and it would artificially
>affect the score of your results.
>
>
>
>
>-Hoss
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
>For additional commands, e-mail: java-user-help@lucene.apache.org
>
>
>
>


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



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


Mime
View raw message