Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Build a calendar table where
week 1 starts on 12/24/22
week 2 starts on 12/31/22
all the way to week 52 starts on 12/16/23
and week 1 starts on 12/23/23
and so on
Solved! Go to Solution.
maybe you can try this
Column =
VAR _DATEDIF=DATE(YEAR('calendar'[Date]),12,31)-'calendar'[Date]
var _DATEDIF2= IF(_DATEDIF<=7,('calendar'[Date]-DATE(YEAR('calendar'[Date]),12,24)+1),('calendar'[Date]-DATE(YEAR('calendar'[Date])-1,12,24)+1))
RETURN ROUNDUP(_DATEDIF2/7,0)
Proud to be a Super User!
maybe you can try this
Column =
VAR _DATEDIF=DATE(YEAR('calendar'[Date]),12,31)-'calendar'[Date]
var _DATEDIF2= IF(_DATEDIF<=7,('calendar'[Date]-DATE(YEAR('calendar'[Date]),12,24)+1),('calendar'[Date]-DATE(YEAR('calendar'[Date])-1,12,24)+1))
RETURN ROUNDUP(_DATEDIF2/7,0)
Proud to be a Super User!