Hi!

I have some trouble to use the inclusive range search explained in
Lucene in Action in ch. 2.5.5

What I do is to add several fields to the index this way:

document.add(Field.Keyword("id", key));
document.add(Field.Keyword("type", type));
document.add(Field.Text("text",text));
document.add(Field.Text("date",date));

The focus lies on "Field.Text("date", date)" where date is a String of
the format YYYYMMDD.

My search goes this way:

search = "date:[20040101 TO 20040101]  Paris"
Query query = QueryParser.parse(search.trim(), "text", new StandardAnalyzer());
Hits hits = indexSearcher.search(query);


Somehow this range search does not work. I still get the same results
as without the date:[..]


Can anyone give me a hint how to use this inclusive range search?

Thanks!

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to