I have a series of temperature values with minute resolution and want to find all instances in which which the temperature dropped sharply overnight (say, over 8h) by more than X degrees.
I could do this on the client side by iterating over each temperature currTemp
in the series,
SELECT t AS currTemp FROM temps
storing the current time as currTime
, then running another InfluxDB querry looking ahead up to 8 hours:
SELECT t FROM temps
WHERE t < currTemp - X
AND time >= currTime AND time < currTime + 8h
But that will run a ton of queries (24 * 60 per day).
Is there a way to have InfluxDB do all the processing, perhaps with subqueries?