Aggregate data with InfluxQL |
Aggregate or apply selector functions to data with InfluxQL |
Use InfluxQL aggregate and selector functions to perform aggregate operations on your time series data.
|
influxdb3_enterprise |
name |
parent |
identifier |
Aggregate data |
Query with InfluxQL |
query-influxql-aggregate |
|
|
203 |
|
/influxdb3/enterprise/reference/influxql/functions/aggregates/ |
/influxdb3/enterprise/reference/influxql/functions/selectors/ |
|
##### Aggregate fields by groups
```sql
SELECT
MEAN(temp) AS mean,
FIRST(hum) as first,
FROM home
GROUP BY tag
```
##### Aggregate by time-based intervals
```sql
SELECT
MEAN(temp),
sum(hum),
FROM home
WHERE time >= now() - 24h
GROUP BY time(1h),room
```
|
/shared/influxdb3-query-guides/influxql/aggregate-select.md |