...
Code Block | ||
---|---|---|
| ||
def date = api.parseDate("yyyy-MM-dd", "2018-01-24") def week = api.getDatamartContext().calendar().getWeek(date) return week |
Similarly, other time dimensions such as Month, Quarter and Year can be retrieved by getMonth(date)
, getQuarter(date)
and getYear(date)
methods respectively.
Warning |
---|
These functions ( |
...