Re: Solr Negative query

2010-11-15 Thread Yonik Seeley
On Mon, Nov 15, 2010 at 12:42 AM, Viswa S wrote: > > Apologies for starting a new thread again, my mailing list subscription > didn't finalize till later than Yonik's response. > > Using "Field1:Val1 AND (*:* NOT Field2:Val2)" works, thanks. > > Does my original query "Field1:Value1 AND (NOT Fiel

RE: Solr Negative query

2010-11-14 Thread Viswa S
/www.lucidimagination.com To: solr-user@lucene.apache.org Subject: Solr Negative query Date: Sun, 14 Nov 2010 13:32:51 +0530 Dear Solr/Lucene gurus, I have run into a weird issue trying use a negative condition in my query. Parser:StandardQueryParserMy Query: Field1:Val1 NOT Field2:Val2Resolved as:

Re: Solr Negative query

2010-11-14 Thread Yonik Seeley
On Sun, Nov 14, 2010 at 4:17 AM, Leonardo Menezes wrote: > try > Field1:Val1 AND (*:* NOT Field2:Val2), that shoud work ok That should be equivalent to Field1:Val1 -Field2:Val2 You only need the *:* trick if all of the clauses of a boolean query are negative. -Yonik http://www.lucidimagination.c

Re: Solr Negative query

2010-11-14 Thread Leonardo Menezes
try Field1:Val1 AND (*:* NOT Field2:Val2), that shoud work ok On Sun, Nov 14, 2010 at 9:02 AM, Viswa S wrote: > > Dear Solr/Lucene gurus, > I have run into a weird issue trying use a negative condition in my query. > Parser:StandardQueryParserMy Query: Field1:Val1 NOT Field2:Val2Resolved as: > F

Solr Negative query

2010-11-14 Thread Viswa S
Dear Solr/Lucene gurus, I have run into a weird issue trying use a negative condition in my query. Parser:StandardQueryParserMy Query: Field1:Val1 NOT Field2:Val2Resolved as: Field1:Val1 -Field2:Val2 The above query never returns any document, no matter how we use a paranthesis. I did see some su