Re:dash and ElasticSearch


#1

Hi All,

I have an elasticsearch query, as follows :-

{
“size”: 0,
“query”: {
“match_all”: {}
},
“aggs”: {
“statusCode”: {
“terms”: {
“field”: “statusCode”
}
}
}
}

The corresponding re:dash query is :-

{
“index”: “url_entries”,
“size”: 0,
“query”: {
“match_all”: {}
},
“aggregations”: {
“statusCode”: {
“terms”: {
“field”: “statusCode”
}
}
}
}

It runs in redash, but does not give me an output

The usual output from elasticsearch is :-

{
“took”: 122,
“timed_out”: false,
“_shards”: {
“total”: 5,
“successful”: 5,
“failed”: 0
},
“hits”: {
“total”: 5534658,
“max_score”: 0,
“hits”: []
},
“aggregations”: {
“statusCode”: {
“doc_count_error_upper_bound”: 0,
“sum_other_doc_count”: 0,
“buckets”: [
{
“key”: 200,
“doc_count”: 5067933
},
{
“key”: 301,
“doc_count”: 453531
},
{
“key”: 404,
“doc_count”: 13194
}
]
}
}
}