Forum Discussion
DAX: Filter on Multiple Date Columns
- 5 years ago
Hi, Titatovenaar2
According to your description and sample pbix file, I can roughly understand your requirement, I think you can just use this measure to apply as the visual filter of the table chart:
Flag = VAR _selectedmonth = MONTH ( MAX ( 'Mutations_Period'[StartDate] ) ) RETURN IF ( MONTH ( MAX ( 'Mutations'[StartDate] ) ) = _selectedmonth || MONTH ( MAX ( 'Mutations'[EndDate] ) ) = _selectedmonth, 1, 0 )Then go to the table chart to apply the visual filter like this:
And you can get what you want.
You can download my test pbix file below
Thank you very much!
Best Regards,
Community Support Team _Robert Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, Titatovenaar2
According to your description and sample pbix file, I can roughly understand your requirement, I think you can just use this measure to apply as the visual filter of the table chart:
Flag =
VAR _selectedmonth =
MONTH ( MAX ( 'Mutations_Period'[StartDate] ) )
RETURN
IF (
MONTH ( MAX ( 'Mutations'[StartDate] ) ) = _selectedmonth
|| MONTH ( MAX ( 'Mutations'[EndDate] ) ) = _selectedmonth,
1,
0
)
Then go to the table chart to apply the visual filter like this:
And you can get what you want.
You can download my test pbix file below
Thank you very much!
Best Regards,
Community Support Team _Robert Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.