Mailing List Archive

Wildcard query
Hi,

Please find attached a patch to the class:
org.apache.lucene.search.WildcardTermEnum.

This patch replaces the 'wildcardEquals' function - it originally only
matched against 1 or more characters in place of a * character if the
wildcard was at the end of the term. The desired behaviour would be for
zero or more characters, as is the case with PrefixQuery. I expect most
people didn't notice the existing behaviour, as the query parser creates
PrefixQuery objects for such queries by default.

This patch also adds comments to the code. Is it suitable to be included
in the main Lucene source?

Regards,

--
Lee Mallabone.
Granta Design Ltd.