Jumping on AWS Timestream, I've some trouble with the grafana integration:
I've build a query that returns a count of events grouped by day and "thing" - and would like to show that in a graph. Doesn't even matter which one.
In a table, the data is displayed fine, and it can also be graph'd - but there is no recognition of the series
- so all data is shown in one series.
Here is the SQL query:
SELECT BIN(time,1d) AS "time",dimension_name AS "series",count(measure_name) AS "metric"
FROM "event"."data"
WHERE "measure_name" = 'code' AND $__timeFilter
GROUP BY BIN(time,1d),dimension_name
ORDER BY 1
Here is an excerpt of the data:
What can I do so that grafana recognizeses the dimension_name
as the denominator for a series?
Okay, after some more digging, I think I found the right thing on the (sparse) documentation. Subqueries are the answer!
Displays beautifully in grafana: