lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Uwe Schindler" <...@thetaphi.de>
Subject RE: how to create a range query with string parameters
Date Tue, 17 May 2011 12:02:58 GMT
Hi,

Query q = new TermRangeQuery(...)

Uwe

-----
Uwe Schindler
H.-H.-Meier-Allee 63, D-28213 Bremen
http://www.thetaphi.de
eMail: uwe@thetaphi.de


> -----Original Message-----
> From: G.Long [mailto:jdevgl@gmail.com]
> Sent: Tuesday, May 17, 2011 1:53 PM
> To: java-user@lucene.apache.org
> Subject: how to create a range query with string parameters
> 
> Hi there :)
> 
> I would like to perform a range query on a lucene index. I'm using lucene
3.1
> api.
> I looked at the javadoc and found a rangeQueryNode but i'm not sure how to
> use it.
> 
> I've got a field "article" in my index which is indexed this way :
> 
> entry.add(new Field("article", article, Field.Store.YES,
> Field.Index.ANALYZED));
> 
> Now I would like to create a query such as :
> 
> +article:[L. 140-1 TO L.145-2]
> 
> I didn't manage to find code sample on the web. Could someone give me a
> hand please?
> 
> Regards :)
> 
> 
> ---------------------------------------------------------------------
> 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