Can I skip group-by for singlestat metric?

My service is logging stats like request latency to Elasticsearch that I want to display in Grafana. I’m trying to make singlestat panels that reflect the average and 95-percentile latency for all requests over the displayed time period, but I can’t figure out a way to do it accurately.

The problem is that if I group by Date Histogram and then aggregate again by picking “avg” from the Options tab, I end up getting an average of averages of latency in each time bucket, which usually isn’t the same as the average latency over the entire time period.

I tried to get around this by defining a custom interval that spanned the entire time range shown, but Grafana doesn’t allow an interval step count of 1.

I also tried to group everything into the same bucket by grouping by a Term that I knew would be the same across all documents, but I get the following error:

TypeError: Cannot read property 'toString' of undefined
at a.isMsResolutionNeeded (
at new a (
at b.seriesHandler (
at (native)
at b.onDataReceived (
at f.emit (
at a.emit (
at b.handleQueryResult (
at g (

Is there something I’m missing? Is there a way tell Grafana that I don’t want to group-by anything at all for singelstat metrics?

Sadly the singlestat panel only supports time series so you need a date histogram. One workaround is to just add a interval 1y as the date histogram group by to only get one bucket back.

1 Like

So sad. I got this issue today.

Now i think just “Table” panel can support ES terms aggregation.

I have tried “Pie chart panel” plugin and “World Map panel” plugin. Table panel is the only way.