I am currently running Grafana 6.6.2 and InfluxDB version: 1.7.10.
I want to use Integral to convert from Watts (W) to Watt Hours.
I have W data approx. every 20 seconds for the last 2 months.
If I run this query in Influx: (last hour of data)
SELECT integral(“Energy_Usage”,1h) AS “Energy_Usage” FROM “dev_db_sensors”.“autogen”.“esp” WHERE time > :dashboardTime: AND time < :upperDashboardTime: AND “Device”=‘esp_03’
I get a result of 213.6 which is correct.
If I run the below query in Grafana: (last hour also with 1h relative time override)
SELECT integral(“Energy_Usage”,1h) FROM “esp” WHERE (“Device” = ‘esp_03’) AND $timeFilter
I get a result of 28821695.
I can run other integral queries on some other test data I have (writing 100 to database every minute) and it turns out fine.
Ddistinct data to show range: