githubEdit

Query

circle-info

Below queries use data from kagglearrow-up-right

Grep documents

query all

return all of index's documents. default return 10 documents.

also response has total document count. but not perfect.

GET news_headlines/_search
...
"hits": {
    "total": 10000,
    "relation": "gte"
    },
...

track_total_hits

order query to tracking all hit documents.

GET news_headlines/_search
{
    "track_total_hits": true
}

now we can see property relation's value gonna eq as equal.

Make boundaries

Range

return documents write down 2015 and between "06-20" and "09-22"

Aggregations

return documents about "category"

This time we do not check property "hits". check "aggregations"

response like below:

and next, let's combine query and aggregation.

Last updated