Bug? when searching on int/double and date range combined

Hello,

I have a field "price" which is a double, and a field "insert_date" which is a datetime field. When I do a range search on the price field all works fine, same goed for the insert_date. But when I do a combined range search on both of then with the settings below I get an error.

bool: {
    must: [
        {
            range: {
                price: [
                    {
                        gte: "200"
                    },
                    {
                        lt: "600"
                    }
                ],
                insert_date: [
                    {
                        gte: "2016-09-13 05:01:14"
                    }
                ]
            }
        }
    ]
}

The error that i get is:

Fatal error: Uncaught Elasticsearch\Common\Exceptions\BadRequest400Exception: {"error":{"root_cause":[{"type":"parse_exception","reason":"failed to parse date field [600] with format [yyyy-MM-dd HH:mm:ss]"}],"type":"search_phase_execution_exception","reason":"all shards failed","phase":"init_scan","grouped":true,"failed_shards":[{"shard":0,"index":"data_standard_13_6_nl_test","node":"w115E6KmTiuBeW7RmJ_feQ","reason":{"type":"parse_exception","reason":"failed to parse date field [600] with format [yyyy-MM-dd HH:mm:ss]","caused_by":{"type":"illegal_argument_exception","reason":"Invalid format: \"600\" is too short"}}}]},"status":400}

I managed to figure out a workaround by putting both fields in its own range. But I'm still wondering if this is a bug or a feature?

bool: {
    must: [
        {
            range: {
                price: {
                    gte: "200",
                    lt: "600"
                }
            }
        },
        {
            range: {
                insert_date: {
                    gte: "2016-09-13 05:01:14"
                }
            }
        }
    ]
}

The range query can accept only one field/range, if you want to do two range queries you need to add a must clause:

{
   "query": {
      "bool": {
         "must": [
            {
               "range": {
                  "price": {
                     "gte": "200",
                     "lt": "600"
                  }
               }
            },
            {
               "range": {
                  "insert_date": {
                     "gte": "2016-09-13 05:01:14"
                  }
               }
            }
         ]
      }
   }
}
```

I think this is a parsing bug - that first example should have had a more obvious error message. I've opened an issue for it. @barry1, can you reply over there with the version of Elasticsearch you hit this issue in?

Great, thanks. I replied on the bug report.