Span Multi with range query

Hi All,

I am trying to do date range query within span_multi but I get below error. Any suggestions ?

Error : "unsupported_operation_exception: unsupported inner query, should be org.apache.lucene.search.MultiTermQuery but was org.apache.lucene.search.IndexOrDocValuesQuery"

Query

{
"query": {
"span_multi":{
"match":{
"range" : {
"ts" : {
"gt" : "2017",
"format": "dd/MM/yyyy||yyyy"
}
}
}
}
}
}

The span_multi accepts only multi-terms queries like prefix, wildcard or regexp. It also accepts the range query but only if the field is a keyword or text field. Span queries need to access the position of each match and numeric and date fields do not record this information.

Thanks for clarification.

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