lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Avi Steiner <astei...@varonis.com>
Subject BooleanQuery and WordDelimiterFilter
Date Mon, 01 May 2017 06:34:31 GMT
Hi

I have  a question regarding the use of query parser and BooleanQuery.

I have 3 documents indexed.
Doc1 contains the words huntman's and huntman
Doc2 contains the word huntman's
Doc3 contains the word huntman

When I search for huntman's I get Doc1 and Doc2
When I search for +huntman's I get Doc1, Doc2 and Doc3

As far as I understand, when I search for huntman's it should return documents with both huntman
and huntman's (using WordDelimiterFilter)
I also know that plus sign means that the term must be in document and the absence of plus
(or minus) sign means that the term may or may not be in document as explained here: https://lucidworks.com/2011/12/28/why-not-and-or-and-not/

So I don't understand the combination of these two properties.
I think I understand why +huntman's returns Doc3 as well, because it can be translated to
+(huntman's OR huntman), which means: must be one of the following: huntman's or huntman.
But I don't understand why Doc3 is not returned by huntman's as well. Isn't it translated
to huntman's OR huntman?

Thanks

Avi


________________________________
This email and any attachments thereto may contain private, confidential, and privileged material
for the sole use of the intended recipient. Any review, copying, or distribution of this email
(or any attachments thereto) by others is strictly prohibited. If you are not the intended
recipient, please contact the sender immediately and permanently delete the original and any
copies of this email and any attachments thereto.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message