QueryStringQuery interpretation bug ES 6.2.4

Hi,
I´ve run into problems after upgrading Elastic from 5.6.3 to 6.2.4 using QueryStringQuery. Apparently the new version has some issue in interpretation of search query when addressing specific field to search in.

Let´s say I want to find documents, that have "someValue" in specific field and "test" word anywhere else. I´m using QueryStringQuery with type:cross_fields setting. The index doesn´t have _all field, as it is deprecated in ES v6.

If the query is
test some_field:someValue
then it returns nothing.

If the query is:
some_field:someValue test
then results are quite as expected.

I´ve tried using _validate API with explain parameter to get these results.

For the first (wrong) case:
{ "valid" : true, "_shards" : { "total" : 1, "successful" : 1, "failed" : 0 }, "explanations" : [ { "index" : "the_index", "valid" : true, "explanation" : "+(+(blended(terms:[ field1:test, field2:test, ... fieldX:test]) | MatchNoDocsQuery(\"failed [fieldY] query, caused by illegal_argument_exception:[Cannot search on field [fieldY] since it is not indexed.]\") | ()~1.0) +()~1.0) #*:*" } ] }

For the second (correct) case:
{ "valid" : true, "_shards" : { "total" : 1, "successful" : 1, "failed" : 0 }, "explanations" : [ { "index" : "the_index", "valid" : true, "explanation" : "+(+some_field:someValue +(blended(terms:[ field1:test, field2:test, ... fieldX:test]) | MatchNoDocsQuery(\"failed [fieldY] query, caused by illegal_argument_exception:[Cannot search on field [fieldY] since it is not indexed.]\") | ()~1.0)) #*:*" } ] }

It used to work in 5.6.3 and I can´t find anything wrong with my query, so I guess it is new fault. Or is there any reasonable explanation for this different behavior? Thank you.

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