I am trying search with elasticsearch with range query. (PHP)
This is my source code
$searchParams['body']['query']['range']['order_no']['gte'] = "2000";
$searchParams['body']['query']['range']['order_no']['lte'] = "2001";
=
{
"query": {
"range": {
"order_no": {
"gte": 2000,
"lte": 2001
}
}
}
}
But in result it have order_no:
2000
2001
2000001
200000
....
I want show only
2000
2001
This field have mapping:
"order_no" : {
"type" : "string",
"index" : "not_analyzed"
}
How can fix it?