Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
Today, I have a separate Date table and a Sales table.
This time I was creating a rolling average with a quick measure, using the Sales amount field in the sales table and the primary Date field on the date table.
The problem is when I am trying to filter the year using a slicer, the rolling average graph is showing 12 month forward. This makes sense since it got data from 12 months back. But how do I stop it from showing dates 12m forward?
I can't figure this one out.
Instead of pasting the examples in here, I have shared a simple Power BI file in the link below.
The screenshow shows the problem:
Solved! Go to Solution.
You may try adding IF.
RETURN IF ( YEAR ( __LAST_DATE ) IN ALLSELECTED ( 'Calendar'[Year] ),
You may try adding IF.
RETURN IF ( YEAR ( __LAST_DATE ) IN ALLSELECTED ( 'Calendar'[Year] ),
Thanks!
Really saved my day, and week, and year!
How can I do that in my case as shown below?
I don't need the future dates (oct to dec 2020):
My DAX for the one measure used in this axis:
Thanks in advance.
Marcos
User | Count |
---|---|
139 | |
113 | |
103 | |
73 | |
63 |
User | Count |
---|---|
136 | |
125 | |
107 | |
70 | |
61 |