Forum Discussion
jfajar
2 years agoNew Member
Is In YTD Filter
Hi! I have a column called "isinytd" which is a "Yes" or "No" Column. When "Yes" is selected, the current output gives all the months YTD - Jan 2023 To Oct 2023 However, I need a new calc...
- 2 years ago
jfajar Is that a calculated column? Are both Date and IsInYTD columns in the same table (Calendar) ? Not sure what's going on with the DAX solution. In Power Query you could do this:
if Date.IsInYearToDate([Column1]) = true and [Column1] <= Date.EndOfMonth(Date.AddMonths(Date.From(DateTime.LocalNow()), -1)) then "YTD" else "No YTD")
Greg_Deckler
2 years agoCommunity Champion
jfajar Is that a calculated column? Are both Date and IsInYTD columns in the same table (Calendar) ? Not sure what's going on with the DAX solution. In Power Query you could do this:
if Date.IsInYearToDate([Column1]) = true and [Column1] <= Date.EndOfMonth(Date.AddMonths(Date.From(DateTime.LocalNow()), -1)) then "YTD" else "No YTD")
jfajar
2 years agoNew Member
Greg_Deckler Thank you! This was exactly what I needed!