1개 답변
- 최신
- 최다 투표
- 가장 많은 댓글
0
To answer my own question:
One way to do this is with a following type of query:
-- Get data points for both CO2 and humidity
SELECT
time,
MAX(if(measure_name = 'CO2', measure_value::double)) AS CO2_ppm,
MAX(if(measure_name = 'humidity', measure_value::double)) AS humidity_percent
FROM "MyTimestreamDB"."myTable"
WHERE
time >= ago(10m)
AND measure_name IN ('CO2', 'humidity')
AND deviceId='6a087171-400c-4851-a82b-ceab383b421c'
GROUP BY time
ORDER BY time DESC
답변함 3년 전
관련 콘텐츠
- AWS 공식업데이트됨 2년 전