Caution Required While Grouping in Kusto
Caution Required While Grouping in Kusto
Here’s how you can write the query to slice records by 1 microsecond and get the
count:
```kql
TableName
| summarize Count = count() by bin(TimestampColumn, 1µs)
| order by TimestampColumn asc
```
### Explanation:
- `bin(TimestampColumn, 1µs)`: This function slices the time by microsecond
intervals.
- `summarize Count = count()`: This aggregates the records for each microsecond
slice.
- `order by TimestampColumn asc`: Orders the results chronologically.
### Caution:
- Grouping by such a small interval (1µs) may not always be practical depending on
the volume of data. If your timestamp data doesn’t have microsecond-level
precision, you might not see much value in grouping at this level.