Summary
Add server-side time-series downsampling and compact SQL charting functions so dashboards can reduce and visualize large datasets without moving every raw row to the client.
The SUBSAMPLE SQL clause supports multiple shape-preserving strategies:
- LTTB (Largest Triangle Three Buckets)
- M4
- MinMax
- Uniform
- Cadence
- Swinging Door Trending (SDT)
SELECT ts, temperature
FROM telemetry
SUBSAMPLE LTTB(1_000);
Charting functions render compact market-data visualizations directly in SQL results:
ohlc_bar() / ohlc_bar_labels() for OHLC candlesticks
depth_chart() / depth_chart_labels() for bid/ask market depth
Motivation
High-frequency time-series often contain far more points than a chart can display. Sending all rows to a browser wastes query, network, and client resources, while simplistic sampling can hide peaks and important shape changes.
Server-side downsampling returns a bounded, representative dataset suitable for dashboards and exploratory analysis. The SQL charting functions complement it by making OHLC and order-book structure immediately visible in the Web Console and text-based query results.
Use cases include:
- fleet and sensor dashboards over dense telemetry
- long-range visualization of high-frequency signals
- OHLC inspection and market-data analysis
- order-book depth visualization
- lower-latency dashboards with reduced result sizes
Related
Summary
Add server-side time-series downsampling and compact SQL charting functions so dashboards can reduce and visualize large datasets without moving every raw row to the client.
The
SUBSAMPLESQL clause supports multiple shape-preserving strategies:Charting functions render compact market-data visualizations directly in SQL results:
ohlc_bar()/ohlc_bar_labels()for OHLC candlesticksdepth_chart()/depth_chart_labels()for bid/ask market depthMotivation
High-frequency time-series often contain far more points than a chart can display. Sending all rows to a browser wastes query, network, and client resources, while simplistic sampling can hide peaks and important shape changes.
Server-side downsampling returns a bounded, representative dataset suitable for dashboards and exploratory analysis. The SQL charting functions complement it by making OHLC and order-book structure immediately visible in the Web Console and text-based query results.
Use cases include:
Related
SUBSAMPLEimplementation: feat(sql): add SUBSAMPLE clause with LTTB, M4, MinMax, uniform, and cadence downsampling questdb#7013