Using Grafana cloud with Influxdb3/InfluxQL. Trying to get specific time periods within a window. This works: SELECT time, extruder_target FROM "gantry" WHERE $timeFilter
However, this does not: SELECT time, extruder_target FROM "gantry" WHERE time > $timeFrom and time < $timeTo
The error I get is: InfluxDB returned error: failed to parse query: missing parameter: timeFrom
I did not find the documentation that would explain that the $timeFilter macro would exist or work, I looked at Query Editor | Grafana Cloud documentation. Also, no mention of $timeTo either, so that was just a guess from my part.
So, how do I get the start&end times of the time picker period with InfluxQL?
Thanks. I believe that documentation refers only to the SQL query editor. I did try $__timeFrom and $__timeTo, and they do work with SQL, but the do not work with influxSQL:
SELECT extruder_target FROM "gantry" WHERE time > $__timeFrom and time < $__timeTo
[sse.dataQueryError] failed to execute query [A]: InfluxDB returned error: failed to parse query: missing parameter: __timeFrom
Ok, thanks. So it seems my grafana.net is broken. The grafana I am using is “Grafana Cloud”, the SaaS service on “grafana.net”. Sorry, I do not know how to get the version they are running on that platform. I would hope it is relatively recent, but could of course be that they run an older version.
Perhaps I’ll need to try log a support case with Grafana.