Getting wrong result, while using range query as query string

When you do:

"query": "[108 TO 110]"

By default, it will look in the _all field for terms to match the above
criteria. The _all field is a concatenation of all your field values in the
JSON document (which will include fields other than price).

When you do:

"query": "price:[108 TO 110]"

You are telling ES to only look in the price field to match the range.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/0da5e183-33db-410f-bf8f-781893269dd9%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.