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.
I'm crearing a Dashboard that when you slect a Date in a slicer you atomatically get a Graph with the latest N Months in the past, but I need that the silcer also filters my tables so I can show only data form the slected Date.
For example, if I filter December 2019, I want my Matrixs and Pie chart to show data only from December 2019 and my Line chart should show me from December 2019 to November 2018.
As you can see I could make a Line chart that correctly shows Dates from December 2019 to November 2018. In order to create that I follow the steps from Parker Stevens (https://bielite.com/blog/last-12-months-from-selected-date-trailing-12-months-ttm/) that suguets to create a disconnected date table in order to manage filters in the graph. But using this method of a disconnected date table doesn't filters the Matrixs and Pie chart I have.
It may sound obvious, but if I try to relate my Date Table with my Fact Table now I can filter my Matrixs and Pie Chart, but my Line chart does not filter the way I want:
Is there a way to filter the date from my Fact Table with the value I choose from silcer with the Date Table without being related? I tried to use SELECTEDVALUE but it's not giving me the desire result.
Thanks in advance for your help!
@Anonymous
You may take a look at the following posts.
Thank you very much @v-chuncz-msft
It seems to be working but now I have another problem, inside my Matrixs I'm using SAMEPERIODLASTYEAR for calculating Growth and Power BI returns: Function 'SAMEPERIODLASTYEAR' expects a contiguous slection when the date column is not unique, has gaps or contains time portion. I think is because the measure in the Visual Level FIlters is only filtering one date, the selected one, so I tried to include both dates, the selected one and the one from last year like this:
Slicer =
VAR Slicer =
SELECTEDVALUE('Date'[Date])
VAR FactTable =
MAX('Flat Files FlexView'[Date])
VAR SlicerLastPeriod =
EDATE(Slicer,-12)
VAR FactTableLastPeriod =
EDATE(FactTable,-12)
RETURN
IF
(
OR
(
Slicer = FactTable,
SlicerLastPeriod = FactTable
),
1,
0
)
But this is not working for my calculations in my Matrixs.
Thanks in advance!
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 |
---|---|
114 | |
99 | |
82 | |
70 | |
60 |
User | Count |
---|---|
149 | |
114 | |
107 | |
89 | |
67 |