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.
Hello,
I need your help. I have been trying lots of things, but I could not manage to get what I want to:
I have this Between Calendar Filter in my report, but I want the widgets to behavior a bit different:
Could you help me?
Thanks a lot
Solved! Go to Solution.
@Alejandro,
Please create a date table using DAX below. Ensure that there is no relationship between the date table and your original table.
date = CALENDARAUTO()
Create the following measure in your original table, and then use the date field of date table to create a slicer.
Last 13 month = var Ldate=MAX('date'[Date]) var Fdate=date(year(edate(Ldate,-13)),month(edate(Ldate,-13)),1) return IF(MIN('Yourtable'[DateKey])<Fdate,BLANK(),IF(MIN('Yourtable'[DateKey])>Ldate,BLANK(),yourcalculation))
There is a similar thread for your reference.
https://community.powerbi.com/t5/Desktop/Show-last-13-months-based-on-user-single-slicer-selection/t...
Regards,
Lydia
@Alejandro,
Please create a date table using DAX below. Ensure that there is no relationship between the date table and your original table.
date = CALENDARAUTO()
Create the following measure in your original table, and then use the date field of date table to create a slicer.
Last 13 month = var Ldate=MAX('date'[Date]) var Fdate=date(year(edate(Ldate,-13)),month(edate(Ldate,-13)),1) return IF(MIN('Yourtable'[DateKey])<Fdate,BLANK(),IF(MIN('Yourtable'[DateKey])>Ldate,BLANK(),yourcalculation))
There is a similar thread for your reference.
https://community.powerbi.com/t5/Desktop/Show-last-13-months-based-on-user-single-slicer-selection/t...
Regards,
Lydia
I am thinking that you are going to have to disconnect your date slicer from that visual. Then, you could theoretically adjust your measure to do something like:
Measure = VAR __maxDate = MAX('Table'[Date]) //get the latest date in your slicer VAR __minDate = DATE(YEAR(__maxDate)-1,MONTH(__maxDate)-1,DAY(__maxDate)) //approximately 13 months, probably a better way to do this but this is for an example. VAR __table = FILTER('Table1','Table1[Date]>=__minDate && 'Table1[Date]<=__maxDate //create a filtered temp table RETURN //Do measure calculation stuff here based on your temp table.
OK, I don't have your measure formula so can't be more specific. But, in theory, this should only return a value for the measure for your desired date range.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
100 | |
80 | |
64 | |
57 |
User | Count |
---|---|
146 | |
110 | |
93 | |
84 | |
67 |