Continiouse Queries and Retention Policies

Hey there,

Our team is trying to get a CQ running but we fail over and over again.
We created two new RPs:
name duration shardGroupDuration replicaN default

autogen 0s 168h0m0s 1 true
a_year 8736h0m0s 168h0m0s 1 false
a_day 168h0m0s 168h0m0s 1 false

and created some CQs:
CREATE CONTINUOUS QUERY “cq_temptest3“ ON “smarthomehm“ BEGIN SELECT “mean(value)“ INTO “smarthomehm.autogen.cq_result“ FROM “smarthomehm.autogen.OWM“ GROUP BY time(1h) END
CREATE CONTINUOUS QUERY cq_temptest ON smarthomehm BEGIN SELECT mean(value) INTO smarthomehm.a_year.cq_result FROM smarthomehm.a_day.OWM GROUP BY time(1h) END

In my understanding there has to be a least one new measurement called “cq_result” where the grouped values are written in.
But there isnt!
We tried everything to get it work but we failed over and over. It would be pleasure for me if u can help us!
What are we doing wrong. The CQ are created 1:1 like the once on the InfluxDB guidline but in there case it works and in our case it seems like nothing is doing something.

for your information;
We use Influx shell V1.8.0
running on a Raspi
The database has three measurements which continuously get new data from an MQTT every 10 min
the influxDB is our “base” for grafana which represents the data graphcaly.
Our Idea was to group the data of the measurements in a new measurement so we dont have to store the full high resulution data the whole time.

Hello @lukas_dulli,
Welcome! Sorry to hear you’re having trouble. You don’t need that measurement to exist already, the CQ should create it. Can you please set up the system stats plugin and try creating this query?

 CREATE CONTINUOUS QUERY using_hands ON telegraf BEGIN SELECT min(usage_user) INTO telegraf.autogen.min_hourly_cpu FROM telegraf.autogen.cpu GROUP BY time(1h) END

I just want to try and identify if CQs work at all for you.

Thank you.