Apache Pinot Docs
Search…
latest
week
This section contains reference documentation for the week function.
Returns the ISO week of the year from the given epoch millis in UTC or specified timezone. The value ranges from 1 to 53.

Signature

week(tsInMillis)
week(tsInMillis, timeZoneId)
weekOfYear(tsInMillis)
weekOfYear(tsInMillis, timeZoneId)

Usage Examples

1
select week(1639351800000) AS week
2
FROM ignoreMe
Copied!
week
49
1
select week(1639351800000, 'CET') AS week
2
FROM ignoreMe
Copied!
week
50
1
select weekOfYear(1639351800000) AS week
2
FROM ignoreMe
Copied!
week
49
1
select weekOfYear(1639351800000, 'CET') AS week
2
FROM ignoreMe
Copied!
week
50
Last modified 1mo ago
Copy link