You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »


Continuous Query is a very useful feature for users to query time series data periodically according to the time interval and time range.

For example, using the continuous query described below, the IoTDB downsamples the CPU load metric, and keeps a single average datapoint per 15 minutes grouped by server region:

CREATE CONTINUOUS QUERY "downsampled_cpu_load"
ON database_name
BEGIN
  SELECT mean(value) as value,
  INTO "downsampled.cpu_load"
  FROM cpu_load
  GROUP BY time(15m), region
END

  • No labels