Skip to main content

Count schema changes over time

TL;DR​

Use this when you need to visualize or audit how often schema snapshots occur over time.

Problem / Use case​

You want to track how many schema snapshots are being generated in the system over time to monitor configuration changes or detect unexpected schema churn.

Query​

source system/engine.schema_fields
| groupby snapshotStartTime
aggregate count() as snapshots
| sortby snapshotStartTime asc

This query groups schema field snapshots by their start time, counts how many were recorded per time period, and sorts them chronologically.

Expected output​

snapshotStartTimesnapshots
1759957200000000000416940
1759960800000000000413454
1759964400000000000408979
1759968000000000000422913

Variations​

  • Group by day instead of exact timestamp: groupby formatTimestamp(snapshotStartTime:timestamp, '%Y-%m-%d') aggregate count() as snapshots
  • Filter by schema type to focus on a specific dataset before grouping.
Last updated on
Was this page helpful?