Forum Discussion
monicajsv
2 years agoFrequent Visitor
Relative date filtering
I have a list of elements with a planned end date and I would like to do a relative filtering of the date in the visualization to only show those whose end date is greater than or equal to 6 months a...
some_bih
2 years agoCommunity Champion
Hi monicajsv possible solution as following
If you need measure then it could be like:
Measure test=
CALCULATE (
SUM(Yourtable[somecolumn]),
DATESINPERIOD (
'Date'[Date], -- Your Date key column
TODAY(), -- Today
-6, -- the set needs to contain 6
MONTH -- months
)
)
DAX function DATESINPERIOD
https://learn.microsoft.com/en-us/dax/datesinperiod-function-dax?WT.mc_id=DP-MVP-4025372
Did I answer your question? Kudos appreciated / accept solution!
monicajsv
2 years agoFrequent Visitor
Hello,
I don't need a measure, I just want to be able to filter them.
Thanks for your help, I think I'll use a colum to calculate if the date is within the relative period I need and the use this column to filter.
Regards,