Hey all,
I'm needing some help with a custom column formula. I have a DATE column which I want to add a column which takes that date and will return "LWE" (Last weekend) then "LWE-1" (Last weekend -1) depending on if the date is a Friday to Sunday.
Please find the Example below:
I have been able to do the Week column with the following formula:
if Date.IsInPreviousNWeeks(Date.AddDays([Date],0),1) = true then "LW" else if Date.IsInPreviousNWeeks(Date.AddDays([Date],7),1) = true then "LW-1" else if Date.IsInPreviousNWeeks(Date.AddDays([Date],14),1) = true then "LW-2" else if Date.IsInPreviousNWeeks(Date.AddDays([Date],21),1) = true then "LW-3" else if Date.IsInPreviousNWeeks(Date.AddDays([Date],28),1) = true then "LW-4" else null
But I just can't seem to work out how I can use a similar formula but to bring back whether the date is a weekend date.
Many thanks
Steve
I'm needing some help with a custom column formula. I have a DATE column which I want to add a column which takes that date and will return "LWE" (Last weekend) then "LWE-1" (Last weekend -1) depending on if the date is a Friday to Sunday.
Please find the Example below:
I have been able to do the Week column with the following formula:
if Date.IsInPreviousNWeeks(Date.AddDays([Date],0),1) = true then "LW" else if Date.IsInPreviousNWeeks(Date.AddDays([Date],7),1) = true then "LW-1" else if Date.IsInPreviousNWeeks(Date.AddDays([Date],14),1) = true then "LW-2" else if Date.IsInPreviousNWeeks(Date.AddDays([Date],21),1) = true then "LW-3" else if Date.IsInPreviousNWeeks(Date.AddDays([Date],28),1) = true then "LW-4" else null
But I just can't seem to work out how I can use a similar formula but to bring back whether the date is a weekend date.
Many thanks
Steve