CQ select and compute on non preseected interval

Hi

newbie to influx data , so please apologiz a naive question.

i’m trying to compute and store an “rolling” mean , via a continous query ( need to do it on all incoming Time series)

the probe is that in order to compute a mean you must provide a group by time() qualifiers, but then you are bound to the pres-selected time interval ( aka rounded hour or minute).

CREATE CONTINUOUS QUERY cq_stats ON telegraf
RESAMPLE EVERY 1m FOR 15m
BEGIN SELECT mean(rssi) AS rssi_mean_last_15m INTO telegraf.autogen.mqtt_consumer FROM telegraf.autogen.mqtt_consumer GROUP BY time(15m), app, devaddr END

this return a mean , but only at hour, hour+15m, hour+30m hour+45m

is tere a way to circunven teh issue, and then to get 60 meanss per hour , each one relevant to the 15 previous minutes ?

thanks in advance

Philippe