Forum Discussion
Date filter
| Event | Start date | End date | intheselectedmonthyear |
| 1 | 1/01/2021 | 5/10/2021 | 0 |
| 1 | 5/11/2021 | 1/01/9998 | 1 |
Hi, I have a Month and year filter that comes from the date table, I need to select 2021 and November from the slicer and the above measure (intheselectedmonthyear) should return 0 and 1 as shown above. I tried to havea column called monthyear in the table and have this measure
Thanks for the help.
Anonymous , Assume month is coming from a date table
measure =
var _max = maxx(allselected('Date'), 'Date'[Date])
return
if(_max <= Max(Table[End date]) ,1,0)
2 Replies
- amitchandakSuper User
Anonymous , Assume month is coming from a date table
measure =
var _max = maxx(allselected('Date'), 'Date'[Date])
return
if(_max <= Max(Table[End date]) ,1,0)
- AnonymousNot applicable
An extension to this. I am counting the number of days in a month when a service is active using a start and end date. I need a matrix view and so far I could achieve this.
The issue is for a single id/name for the month of March there are multiple start and end date and I am not able to get the total for a month. Its necessary to have all the start and end dates displayed as well. I tried enabling row totals in the Matrix view but doesnot give the total, just repeats the value.
Thanks,Sreejith