: Wait. If the default op is OR, I thought this query:
: 
: (+category:xyz +price:[100 TO *]) -category:xyz
: 
: meant "with xyz and range, OR without xyz" because without a plus or

Nope.  regardless of hte default op, you've got a BooleanQuery with two 
clauses, one of which is negative.  the other clauses is either mandatory 
because the default op says it should be, or it's mandatory because it's 
the only "SHOULD" clause and there are not "MUST" clauses.

consider it written out a little more simply...

        (+A +B) -A

...the params arround the A and B clauses make them a BooleanQuery 
which we can call X...

        X -A

...and now hopefully it's clear: A is prohibited, and since there aren't 
any mandatory clauses, and there is only one optional clause, that 
optional clause (X) is now mandatory ... Since X = (+A +B), that means (+A 
+B) is mandatory.  

so we get no matches because we can't match A and -A at the same time.

: minus, OR really means SHOULD (which, bizzarely, is not a keyword).

(yeah, it anoyes me that there is no prefix markup for "SHOULD" ... it 
wouldn't be so bad except thta if you change the default op to MUST there 
is no way of expression whole families of queries .. that's why i never 
recomend making the default op MUST)


-Hoss

Reply via email to