lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Filip Anselm <fi...@nable.dk>
Subject Re: How to search between dates?
Date Sun, 04 Sep 2005 07:11:00 GMT
jian => I'll try the RangeQuery first, and if it doesn't give any
perfomance problems I'll just stick to that method - it's easy, simple
and doens't involve other systems. But thanks for info...

How do I combine two queries - one made by the QueryParser and the
programmatically made RangeQuery?

Filip

jian chen wrote:

>Hi, 
>
>The other way maybe, store the date in a separate database, like derby 
>embeded database. Then, do a joint query between the Lucene result and the 
>derby database select result, and merge the two result set into one by 
>handing coding a database intersection like type of operation.
>
>Just a thought but I am looking into using derby to store all the 
>numeric/date data that requires range query, and only store in Lucene the 
>free text data. Then, using a primary key to associate the two. 
>
>Since typically, range query is best handled by B+ tree indexing, so, that 
>is why I want to give derby a try and see how to best integrate it with 
>Lucene.
>
>Cheers,
>
>Jian
>
>On 9/3/05, Otis Gospodnetic <otis_gospodnetic@yahoo.com> wrote:
>  
>
>>You can use the date range query. See:
>>http://lucene.apache.org/java/docs/queryparsersyntax.html
>>http://www.lucenebook.com/search?query=range+query
>>
>>Otis
>>
>>--- Filip Anselm <filip@nable.dk> wrote:
>>
>>    
>>
>>>Hi
>>>
>>>If I add a Field with a date to all my indexed documents... how can I
>>>then search and only get the hits where the date Field is between two
>>>specified dates??
>>>
>>>Thank you in advance!
>>>
>>>Filip
>>>
>>>
>>>---------------------------------------------------------------------
>>>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