On Feb 1, 2007, at 5:03 PM, Peter Keegan wrote:
OK, I see that I'm not the first to discover this behavior of QueryParser.
Can anyone vouch for the integrity of the PrecedenceQueryParser here:

http://svn.apache.org/repos/asf/lucene/java/trunk/contrib/ miscellaneous/src/java/org/apache/lucene/queryParser/precedence/

PrecedenceQueryParser was my tinkering attempt to make it more logically handle precedence. I don't recall the exact issues that occur, though a JIRA issue was just filed with one:

   <https://issues.apache.org/jira/browse/LUCENE-792>
"NOT foo AND baz" is parsed as "-(+foo +baz)" instead of "-foo +bar". (I'm setting parser.setDefaultOperator (PrecedenceQueryParser.AND_OPERATOR) but the issue applies otherwise too.)

I believe the test case points out some potential issues. In other words, PrecedenceQueryParser is a work-in-progress that I no longer am working on myself. Improvements to it welcome. Query parsing is tricky business!

        Erik


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to