Tz field not working - "unable to find time zone America/New_York"

  • What Grafana version and what operating system are you using?

Windows 10 - Grafana v7.4.3 0 InfluxDB 1.8.9

  • What are you trying to achieve?

Add timezone “tz” to query

  • How are you trying to achieve it?

SELECT sum(“value”) / 360 FROM “mcsMQTT” WHERE (“device” = ‘!HOME ENERGY SENSORS_SONOFFBASIC3_SENSOR:ENERGY:Power:TOTAL’) AND $timeFilter GROUP BY time(1d) tz(‘America/New_York’)

  • What happened?

{
“request”: {
“method”: “POST”,
“url”: “api/datasources/proxy/1/query”,
“params”: {
“db”: “MCSMQTT2INFLUXDB”,
“epoch”: “ms”
},
“data”: “q=SELECT%20sum(%22value%22)%20%20%2F%20360%20FROM%20%22mcsMQTT%22%20WHERE%20(%22device%22%20%3D%20’!HOME%20ENERGY%20SENSORS_SONOFFBASIC3_SENSOR%3AENERGY%3APower%3ATOTAL’)%20AND%20time%20%3E%3D%20now()%20-%207d%20GROUP%20BY%20time(1d)%20tz(‘America%2FNew_York’)”,
“precision”: “ms”,
“hideFromInspector”: false
},
“response”: {
“error”: “error parsing query: unable to find time zone America/New_York”,
“message”: “error parsing query: unable to find time zone America/New_York”
}
}

  • What did you expect to happen?

Chart offset to reflect correct timezone (EST) and follow DST (UTC-5 or UTC-4)

  • Can you copy/paste the configuration(s) that you are having problems with?

above

  • Did you receive any errors in the Grafana UI or in related logs? If so, please tell us exactly what they were.

above

  • Did you follow any online instructions? If so, what is the URL?

Anyone? Thanks for your help,

Hi I wonder if you already solved it?

Let me guess, that you are using InfluxDB on Windows. Then it’s InfluxDB issue, not Grafana issue.

Exactly, Influxdb on windows. Thanks for the hint!
Is installing it on linux does solve the issue? I wonder if you already did.
Thanks brother.

Just try and you will see,dunno.

1 Like