lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lee Mallabone <...@grantadesign.com>
Subject [patch] bug with boosts in parsed queries
Date Fri, 06 Sep 2002 09:45:58 GMT
Hi,

Following up a related post I made on lucene-user yesterday, I've
tracked down what I consider to be a bug in the Query parser relating to
boosting boolean queries.

In short, I think it's reasonable for a user to want to boost all the
terms within a set of parentheses like this:

(fred jim bob)^2.0

However, this fails with the current query parser - the boost factor is
silently ignored.

Please find attached a patch that adds two assertions to the query
parser test, demonstrating the above problem. The patch also includes a
minor change to QueryParser.jj to fix the problem and a tweak to
BooleanQuery.toString() to help test it.

Regards,

-- 
Lee Mallabone.
Granta Design Ltd.

Mime
View raw message