lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Carlson <carl...@bookandhammer.com>
Subject Bug? QueryParser may not correctly interpret RangeQuery text
Date Sat, 01 Jun 2002 22:40:10 GMT
I am trying to get date range searching use the range query (maybe a bad
choice vs. DateFilter, but I wanted to be able to use it from the query
string).

So I type in a string like
date:[0czi1ceuk-0d0ouet2k]

When I run this through the QueryParser it return only 1 term. That is the
query gets converted to:

date:[0czi1ceuk-0d0ouet2k-null]


This is because the StandardTokenizer sees <alphanum> <p> <has_digit> as
a
single token.

Note: <p> can be .,-,_,, and a few other things.

What do people think the right way to handle this issue for the range
queries? My suggestion is to do a indexOf() for "-" and create the one or
two tokens. That is, don't use the analyzer to determine what the tokens are
here. Is there a problem with this?

--Peter


--
To unsubscribe, e-mail:   <mailto:lucene-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:lucene-dev-help@jakarta.apache.org>


Mime
View raw message