Last active
June 14, 2018 06:30
-
-
Save kosho/5e7d85f1051cd4365ee238d30de8286e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Search the earthquake dataset with SQL | |
POST /_xpack/sql?format=txt | |
{ | |
"query": "SELECT \"@timestamp\", mag, depth FROM \"ncedc-earthquakes\" where (mag > 7) ORDER BY \"@timestamp\" desc LIMIT 10" | |
} | |
# Translate SQL into QueryDSL | |
POST /_xpack/sql/translate | |
{ | |
"query": "SELECT \"@timestamp\", mag, depth FROM \"ncedc-earthquakes\" where (mag > 7)" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment