I am using Derivative function to calcute bandwidth and send alert via kapacitor,
below is the query
|query(''' SELECT derivative(mean("bandwidth_in"), 1s) *8 as "value" FROM "router"."autogen"."cisco_router" where host = '10.1.11.1' and ( interface_name = 'XXX' or interface_name = 'XXXXX')) AND time < now() GROUP BY time(1s) ''')
.cluster('network')
.period(7m)
.every(6m)
.groupBy(time(10s), *)
and when i try to save this tick script in chronograf i get below error.
failed to parse InfluxQL query: derivative aggregate requires a GROUP BY interval