Re: Confused by queries

2013-01-26 Thread Jack Krupansky
ssage- From: Anders Melchiorsen Sent: Thursday, January 24, 2013 4:28 AM To: solr-user@lucene.apache.org Subject: Re: Confused by queries Hello. That is indeed an excellent article, thanks for pointing me at it. With a title like that, it is no wonder that I was unable to google it on my own.

Re: Confused by queries

2013-01-24 Thread Anders Melchiorsen
Hello. That is indeed an excellent article, thanks for pointing me at it. With a title like that, it is no wonder that I was unable to google it on my own. It is probably the exception in this rule that has been confusing me: If a BooleanQuery contains no MUST BooleanClauses, then a doc

Re: Confused by queries

2013-01-22 Thread Erick Erickson
Solr/Lucene does not implement strict boolean logic. Here's an excellent blog discussing this: http://searchhub.org/dev/2011/12/28/why-not-and-or-and-not/ Best Erick On Tue, Jan 22, 2013 at 7:25 PM, Otis Gospodnetic wrote: > Well, depends on what you indexed. > > Otis > Solr & ElasticSearch Sup

Re: Confused by queries

2013-01-22 Thread Otis Gospodnetic
Well, depends on what you indexed. Otis Solr & ElasticSearch Support http://sematext.com/ On Jan 22, 2013 5:48 PM, "Anders Melchiorsen" wrote: > Thanks, though I am still confused. > > How about this one: > > manu:apple => 1 hit > +name:video => 2 hits > > manu:apple +name:video => 2 hits > > So

Re: Confused by queries

2013-01-22 Thread Anders Melchiorsen
Thanks, though I am still confused. How about this one: manu:apple => 1 hit +name:video => 2 hits manu:apple +name:video => 2 hits Solr ignores the manu:apple part completely? Cheers, Anders. Den 22/01/13 23.16, Jack Krupansky skrev: The first query: name:ipod OR -name:ipod => 0 hits

Re: Confused by queries

2013-01-22 Thread Jack Krupansky
The first query: name:ipod OR -name:ipod => 0 hits The "OR" and "-" are actually at the same level of the BooleanQuery, so the "-" overrides the OR so it's equivalent to: name:ipod -name:ipod => 0 hits For the second query: (name:ipod) OR (-name:ipod) => 3 hits Pure negative queri