Range query is not working in elasticsearch JAVA Client API


I am using ES 6.6.0 version.
I have two indices, both the indices have the fallowing field :
"ts": {
"type": "date"

able to query from one index and not from the other.

If i execute the below query through ES curl API then it works but it is not working when i execute the same query through java client API
{ "range": { "ts": { "from": 1559001262497, "to": 1559009262497, "include_lower": true, "include_upper": true, "boost": 1.0 } } }

Please suggest what could be the reason

What does your code exactly look like?

Please format your code, logs or configuration files using </> icon as explained in this guide and not the citation button. It will make your post more readable.

Or use markdown style like:


This is the icon to use if you are not using markdown format:

There's a live preview panel for exactly this reasons.

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