Versions (relevant - OpenSearch/Dashboard/Server OS/Browser):
OpenSearch 2.11.0
Describe the issue:
The following query fails with this error:
{
"query_string": {
"query": "for \"1 copper pipe \"2",
"default_field": "fulltext_text",
"default_operator": "OR"
}
}
"root_cause": [
{
"type": "illegal_state_exception",
"reason": "field \"fulltext_text\" was indexed without position data; cannot run SpanTermQuery (term=1)"
}
],
Basically the “2” after the ending quote turns the query into a span query and it fails because we did not index position data in our field. I don’t see anything about this behavior in the documentation for query_string. Is this expected behavior?