lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dontspamterry <>
Subject "Contains" query parsed to PrefixQuery
Date Mon, 11 Jun 2007 21:34:30 GMT

Hi all,

I was experimenting with queries using wildcard on an untokenized field and
noticed that a query with both a starting and trailing wildcard, e.g. *abc*,
gets parsed to the PrefixQuery *abc. I did enable the leading wildcard in
the QueryParser to allow the query above to be parsed so I'm wondering is
there any way to get the query parser to parse *abc* as a WildcardQuery and
not a PrefixQuery, short of overriding the applicable query parser methods?
I don't think the parser treats every query with a trailing wildcard as a
PrefixQuery because when I tried, a*b*, it got parsed to a WildcardQuery.
Thanks for any insight!

View this message in context:
Sent from the Lucene - Java Users mailing list archive at

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message