Forum Discussion
How to filter and exclude rows based on date slicer maximum date range?
- Anonymous5 years ago
Hi deb_power123 ,
Have you forgotten to create a "calendar" table?
Measure =
var x1=CALCULATE(MAX('Calendar'[Date]),ALLSELECTED('Calendar'[Date]))
return
IF(DATEDIFF(MAX('student'[LastAttendanceDate]),x1,DAY)<0,1,0)Result:I don't think it can display the rows containing LastAttendedDate as null values. It will make errors.
Hope that's what you were looking for.
Best Regards,
Yuna
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi deb_power123 ,
There seems to be some errors in your description.
There are only 30 days in September and the relationship between "calendar"[Dates] and "Student"[LastAttendanceDate] should be 1:many.
Then you can do some steps as follows.
1. create a measure
filter_test =
var x1=CALCULATE(MAX('Calendar'[Dates]),ALLSELECTED('Calendar'[Dates]))
return
IF(NOT(ISBLANK(MAX('Students'[DateLeft])))&&MAX('Students'[DateLeft])<x1,0,1)
Hope that's what you were looking for.
Best Regards,
Yuna
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- deb_power1235 years ago
Helper V
Thankyou Yuna for the response.Could you please let me know how can I exlude all the rows having null values for "date left "which are falling under the minimum and maximum calendar selected date range?