I am trying to filter between two dates in ElasticSearch but I have the next error
This is the query
{
"query": {
"bool": {
"must": [
{
"match": {
"message": "start_time"
}
},
{
"range": {
"start_time": {
"gte": "09-02-2016",
"lte": "09-02-2016"
}
}
}
]
}
}
}
and the error
{
"error": {
"root_cause": [
{
"type": "query_shard_exception",
"reason": "failed to create query: For input string: \"09-02-2016\"",
"index_uuid": "nLn_JFMDShW_PxAf7vgFyg",
"index": "accidents"
}
],
"type": "search_phase_execution_exception",
"reason": "all shards failed",
"phase": "query",
"grouped": true,
"failed_shards": [
{
"shard": 0,
"index": "accidents",
"node": "x5unJW2PQsquLIpFsi9YQA",
"reason": {
"type": "query_shard_exception",
"reason": "failed to create query: For input string: \"09-02-2016\"",
"index_uuid": "nLn_JFMDShW_PxAf7vgFyg",
"index": "accidents",
"caused_by": {
"type": "number_format_exception",
"reason": "For input string: \"09-02-2016\""
}
}
}
]
},
"status": 400
}
This is the field to filter
And It's an example that how start_time is saved
I had understood that ElasticSearch converts from date to number to have better performance but maybe it's wrong
I would like to be sure about if I am making the query well or why I've this problem

