Hello. I've made a Filter which recognizes special words and return them in a "boosted form", in a QueryParser sense. For instance, when the filter receives "special_word", it returns "special_word^3", so as to boost it. The problem is that the QueryParser understands the boost syntax when the string is given as an argument to the "parse" function, but does not get it when it is generated by a filter in the Analyzer. So, when my filter transforms "special_word" to "special_filter^3", the QueryParser does not create a Query object with "special_word" as value to look for and boost to 3, but with "special_word^3" to search and boost to 1. Of course, it does not match anything.
Does anyone knows a solution to that problem ? Do I have to write my own QueryParser from the beginning or do I just have to correct 2 ot 3 lines of the original QueryParser to make it work the I'd like it to work ? Thanks a lot. Gilles Moyse. -----Message d'origine----- De : Erik Hatcher [mailto:[EMAIL PROTECTED] Envoy� : mercredi 12 novembre 2003 15:16 � : Lucene Users List Objet : Re: Can use Lucene be used for this On Wednesday, November 12, 2003, at 07:34 AM, Hackl, Rene wrote: >>> col2 like %aa% > >> Lucene doesn't handle queries where the start of the term is not known >> very efficiently. > > Is it really able to handle them at all? I thought "*foo"-type queries > were > not supported. They are not supported by the QueryParser, but an API created WildcardQuery supports it. I certainly do not recommend using prefix-style wildcard queries though, knowing what happens under the covers. Erik --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
