Forum Discussion
Overlapping Weeks Between Months in Calendar Logic
- Anonymous1 year ago
Hi Harrisfil ,
I changed the arithmetic logic and you can check the new attachment.
New WeekStart = IF(MONTH('DimDate'[WeekStart])<>MONTH([Date]),[WeekStart]+7,[WeekStart]) New Weeknum = WEEKNUM([New WeekStart],1)An attachment for your reference. Hope it helps!
Best regards,
Community Support Team_ Scott ChangIf this post helps then please consider Accept it as the solution to help the other members find it more quickly.
Thank you for your answer .
i tried it in a full calendar and it is not giving the desired result for allo months across years. For example 31/3/2024 -01/4/2024 it gives same week.
Thanks again for spending time on that 🙂
Hi Harrisfil ,
I changed the arithmetic logic and you can check the new attachment.
New WeekStart = IF(MONTH('DimDate'[WeekStart])<>MONTH([Date]),[WeekStart]+7,[WeekStart])
New Weeknum = WEEKNUM([New WeekStart],1)
An attachment for your reference. Hope it helps!
Best regards,
Community Support Team_ Scott Chang
If this post helps then please consider Accept it as the solution to help the other members find it more quickly.
- Harrisfil1 year ago
Helper I
Thank you very much for your effort and your time