lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 25820] - [PATCH] QueryParser not handling queries containing AND and OR correctly
Date Sun, 15 Feb 2004 17:52:04 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25820>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=25820

[PATCH] QueryParser not handling queries containing AND and OR correctly





------- Additional Comments From morus.walter@gmx.de  2004-02-15 17:52 -------
Two comments on Dougs arguments:

- an empty query will not result in an empty (or null) query but raise a parser
exception. So if it should, this would have to be changed.
The only situation where empty (or null) queries occur is, when a query only
contains stopwords (or, with my patch, contains only prohibited terms).
- while it may be conveniant in some cases to have an empty query as the result,
I would like to distinguish between empty queries and queries returning an empty
result. So if an empty query is returned I'd like to have a simple way of
testing for that.
I suggest a 'isEmpty()' method for the query object, which can be implemented in
the query object always returning false and be overwritten for boolean queries,
where it returns true unless one of clauses is a nonempty query.
Currently you can only use the toString() method to test for empty queries or
have to distinguish the type of query object and if its boolean query look into
it's details yourself.

---------------------------------------------------------------------
To unsubscribe, e-mail: lucene-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: lucene-dev-help@jakarta.apache.org


Mime
View raw message