Re: Inconsistent parsing of pure negative queries inside brackets

2016-07-04 Thread Shawn Heisey
On 7/4/2016 7:04 AM, Rahul Verma wrote: > While tracing a bug in one of our systems we notices some interesting > behavior from Solr. These two queries return different results. I fail > to understand why the second query returns empty results just by > adding brackets. Can you please help us under

Re: Inconsistent parsing of pure negative queries inside brackets

2016-07-04 Thread Erick Erickson
The Lucene query parser is _not_ a boolean query language, see Hossman's excellent explanation here: https://lucidworks.com/blog/2011/12/28/why-not-and-or-and-not/ In this case, add &debug=query to them both and you'll see something like: ---no parens "-cat:electronics +name:test" ---parens "+(-c

Inconsistent parsing of pure negative queries inside brackets

2016-07-04 Thread Rahul Verma
Hi everyone, While tracing a bug in one of our systems we notices some interesting behavior from Solr. These two queries return different results. I fail to understand why the second query returns empty results just by adding brackets. Can you please help us understand this behavior? *1. Without