ToEpochBucket
This section contains reference documentation for the toEpochBucket functions.
Convert epoch milliseconds to epoch , and divided by bucket size (Bucket size is defined in ). The following time units are supported:
Signature
ToEpoch<TIME_UNIT>Bucket(timeInMillis, bucketSize)
Usage Examples
select ToEpochSecondsBucket(1613472303000, 1000) AS bucket
FROM ignoreMe
select ToEpochMinutesBucket(1613472303000, 10) AS bucket
FROM ignoreMe
select ToEpochHoursBucket(1613472303000, 5) AS bucket
FROM ignoreMe
select ToEpochDaysBucket(1613472303000, 10) AS bucket
FROM ignoreMe