Forum Discussion
jnrezk
5 years agoHelper III
Calculating Week Start Date from Week Number
Hi there, I have data by week number like this: but I need to add a column that will show me the week end date like this format: The other complication is that the week numbers are ...
Anonymous
5 years agoNot applicable
HI jnrezk,
The options parameter of weeknum function will change the week number calculation logic. If you want to keep the regular work schedule(Sunday to Saturday) and Monday as result, you can add a '+1' offset to my formulas to change the results.
WeekStart =
VAR cYW =
MAX ( Table[YearWeekNum] )
RETURN
MINX (
FILTER (
CALENDAR ( DATE ( LEFT ( cYW, 4 ), 1, 1 ), DATE ( LEFT ( cYW, 4 ), 12, 31 ) ),
WEEKNUM ( [Date], 1 ) = VALUE ( RIGHT ( cYW, 2 ) )
),
[Date] + 1
)
Regards,
Xiaoxin Sheng
jnrezk
5 years agoHelper III
Hi - sorry no need to add the +1 I found a field that automatically counts the weeks as monday to sunday but the weeks are off as indicated in the image in my other response. I tried your new way with the sunday dates and it didnt solve it either.