lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Otis Gospodnetic <otis_gospodne...@yahoo.com>
Subject Re: QueryParser question - case-sensitivity
Date Thu, 09 May 2002 17:24:28 GMT
Wouldn't that be the Analzyer that you are using?
I don't have the source handy to check it for you, but look for
toLowerCase or some such, and you'll find who's messing with your
queries.
Replace that piece, and you'll keep your upper cases.

Otis

--- Landon Cox <lcox@interactive-media.com> wrote:
> 
> I have a QueryParser/Query question.  These classes (not sure which)
> is
> apparently converting my term values into lowercase even though
> Term's
> values are by default case-sensitive.  I've got non-word text, id's,
> that
> are case sensitive and stored/indexed that way, but query parser is
> not
> respecting my case sensitive search criterion.
> 
> For example, I create a query string:
> 
> id:"templatedata/f2container/data/Course1102043194747042"
> 
> and pass this to the QueryParser.parse() method.  When I dump the
> Query with
> toString() I get:
> 
> +id:templatedata/f2container/data/course1102043194747042
> 
> Naturally, this query fails as I'm expecting a hit on the id with the
> uppercase C.  If I create and index an id all lower case, then the
> query
> succeeds.  Case-sensitivity is important to maintain for querying
> this
> element, especially using it once the hit occurs.
> 
> How do I coerce QueryParser/Query to not 'tolower' my query string?
> or is
> there an alternate method that's more direct which takes my query
> string
> with no modification?
> 
> 
> --
> To unsubscribe, e-mail:  
> <mailto:lucene-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
> <mailto:lucene-user-help@jakarta.apache.org>
> 


__________________________________________________
Do You Yahoo!?
Yahoo! Shopping - Mother's Day is May 12th!
http://shopping.yahoo.com

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


Mime
View raw message