Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Filtering from multiple date ranges (Can any one tell me is this is the correct approach)

I have 3 slicers to 

roopesh_0-1595993439616.png

 

that query's status date Daterange1 or Datarange3 or Daterange3

roopesh_1-1595993481944.png

created three tables for the dates

roopesh_2-1595993551699.png

DateRange1 = SUMMARIZECOLUMNS(vw_patientListNew[StatusDate].[Date])
DateRange2 = SUMMARIZECOLUMNS(vw_patientListNew[StatusDate].[Date])
DateRange3 = SUMMARIZECOLUMNS(vw_patientListNew[StatusDate].[Date])

created datefinterrange collumn 

roopesh_3-1595993659486.png

DateFilterRange = 
IF(
    
    
    MAX(vw_patientListNew[StatusDate])>=[MinselectedDateRange1] && MAX(vw_patientListNew[StatusDate])<=[MaxselectedDateRange1] ||
    MAX(vw_patientListNew[StatusDate])>=[MinselectedDateRange2] && MAX(vw_patientListNew[StatusDate])<=[MaxselectedDateRange2] ||
    MAX(vw_patientListNew[StatusDate])>=[MinselectedDateRange3] && MAX(vw_patientListNew[StatusDate])<=[MaxselectedDateRange3] 

,1,Blank())

 and adding 

roopesh_4-1595993796622.png

to restrict the table filter.

 

I am not getting the desired results. Can anyone let me know the issue? Thanks

4 REPLIES 4
amitchandak
Super User
Super User
Anonymous
Not applicable

@amitchandak , @AntrikshSharma I removed the measure in a calculated field and it's still not working

roopesh_0-1596025808604.png

roopesh_1-1596025861582.png

 

TimeFrameDateRangeCol1 = 
IF(MAX(vw_patientListNew[StatusDate]) in VALUES(DateRange1[Date]),1)

 

Are you trying to obtain all the dates that are included within those 3 slicers?
AntrikshSharma
Community Champion
Community Champion

What is your desired result?

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.