How to calculate Sales Date dimension

I have one date dimension_group “transaction_date”(Year, month, month num...) and one column sales. I need to create three measures or columns which works dynamically  

  1. Sales of latest year and latest month(Dec 2021)
  2. Sales of latest year and this month(Nov 2021)
  3. Sales of last year and this month(Dec 2020)
Solved Solved
0 22 1,957
1 ACCEPTED SOLUTION

No it won’t. ISOWEEK is an ISO  standard implementation when it comes to days of the week. Starting from Monday  as 1 and ending with Sunday as 7.

If you want to “play with time” and create customised weeks then you would have to translate timeframes selected in Lokker, for example “Last 1 completed Week” to not be a simple calculation of difference of weeks, you would have to shift the days . It’s possible but also hacky - I needed to do it once when a reporting week (for one explore) was Friday - Thursday… 

In short - it’s a nightmare 😄

View solution in original post

22 REPLIES 22
Top Labels in this Space
Top Solution Authors