# Minimum\_should\_match odd behaviour when mixed with stopword fields and cross\_field searches

**URL:** <https://discuss.elastic.co/t/minimum-should-match-odd-behaviour-when-mixed-with-stopword-fields-and-cross-field-searches/93309>\
**Category:** Elasticsearch\
**Created:** [July 16, 2017, 4:46pm UTC](https://discuss.elastic.co/t/minimum-should-match-odd-behaviour-when-mixed-with-stopword-fields-and-cross-field-searches/93309 "2017-07-16T16:46:44Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![es121](https://avatars.discourse-cdn.com/v4/letter/e/898d66/32.png) [@es121](https://discuss.elastic.co/u/es121)\
**Post date:** [July 16, 2017, 4:46pm UTC](https://discuss.elastic.co/t/minimum-should-match-odd-behaviour-when-mixed-with-stopword-fields-and-cross-field-searches/93309/1 "2017-07-16T16:46:45Z")

</div>

Using ES 5.1.1 (Edit: Just upgraded to 5.5.0, same behaviour)

I'm getting some odd behaviour when mixing minimum\_should\_match with differing analyzers, and was wondering if anyone had any insights.

Simplified down, my issue is this:

I have two analysers. One has stopwords (A), and one doesn't(B).

There are two fields.  
" **title**", which uses analyser A (the one with stopwords)

" **keywords**", which uses analyser B.

The stopwords list includes the word "_cat_".

There is one record:  
`{"title": "Hello world", "keywords": "dog"}`

I'm doing the following query:

```
"query" : {
	"multi_match": {
		"query" : "hello cat",
		"type" : "cross_fields",
		"fields": ["title", "keywords"],
		"minimum_should_match" : 2
	}
}

```

Now, in theory there should be no results. The word "cat" doesn't appear anywhere in the data, and minimum\_should\_match is set to 2. Yet this result is returned.

If I change the query term to:  
"_hello cheese_", I rightly get 0 results.

Does anyone know why is this? Any suggestions on how can I work around it to get the desired result would be appreciated?  
Thanks

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [August 13, 2017, 4:46pm UTC](https://discuss.elastic.co/t/minimum-should-match-odd-behaviour-when-mixed-with-stopword-fields-and-cross-field-searches/93309/2 "2017-08-13T16:46:51Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
