Message-
From: Chris Hostetter [mailto:[EMAIL PROTECTED]
Sent: Friday, March 07, 2008 3:23 PM
To: java-user@lucene.apache.org
Subject: Re: Boolean Query search performance
: additional parens normally indicates that you are actually creating
an
: extra layer of BooleanQueries (ie: a BooleanQuery
: additional parens normally indicates that you are actually creating an
: extra layer of BooleanQueries (ie: a BooleanQuery with only one clause for
: look here,
: parens will also be add is each term has a boost value larger than 1.0.
i think you are missreading that code. the needParens
2008/3/6, Chris Hostetter [EMAIL PROTECTED]:
: If I do a query.toString(), both queries give different results, which
: is probably a clue (additional paren's with the BooleanQuery)
:
: Query.toString the old way using queryParser:
: +(id:1^2.0 id:2 ... ) +type:CORE
:
:
Thanks for all replies.
Today when I printed out the query that's generated it does not have the
extra paren's. And query.rewrite(reader).toString() now gives the same
result as query.toString(). All I can figure is I must have changed
something between starting the email and sending it out. The
Beard, Brian skrev:
I'm using lucene 2.2.0.
I'm in the process of re-writing some queries to build BooleanQueries
instead of using query parser.
Bypassing query parser provides almost an order of magnitude improvement
for very large queries, but then the search performance takes 20-30%
longer.
: If I do a query.toString(), both queries give different results, which
: is probably a clue (additional paren's with the BooleanQuery)
:
: Query.toString the old way using queryParser:
: +(id:1^2.0 id:2 ... ) +type:CORE
:
: Query.toString the new way using BooleanQuery:
: +((id:1^2.0)