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've read numerous posts about this, it still doesn't works for me. My scenario is as below -
I have a Date dimension (DimDate) and a Fact (StockAvailability). There are several visuals on the page, and a page level filter that shows data for the last 7 days. However, for one of the visuals, I want the data to be shown for last 3 months, i.e., not limited by 7 days report level filter.
So, I created a measure, clearing up the filter on the StockAvailability using ALL, but that results in a single value for all the dates -
Overall Stock Availability = CALCULATE(AVERAGE([Availability], ALL('StockAvailability'))
Further, I try to re-add the 3-months filter above, but still nothing - I get distinct values this time, but only 7 days worth
Overall Stock Availability = CALCULATE(AVERAGE([Availability]), ALL('StockAvailability'), FILTER(DimDate, [IsLast3Months] = true))
How can I Ignore the 7 days report level filter for this given measure?
Any inputs will be greatly appreciated!
Thanks
This is likely what you are trying to write (i've assumed you have and use a date table):
Overall Stock Availability = CALCULATE( AVERAGE([Availability], DATESINPERIOD( 'Date Table'[Date], LASTDATE('Date Table'[Date]), -3, MONTH ) )
If that doesn't work, you might need to make the AVERAGE line its own measure and try this:
Availability Average = AVERAGE([Availability])
Overall Stock Availability = CALCULATE( [Availability Average], DATESINPERIOD( 'Date Table'[Date], LASTDATE('Date Table'[Date]), -3, MONTH ) )
Unfortunately, with both the above, I get the same result, its limited to 7 days only due to the report level filter.
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 | |
95 | |
80 | |
68 | |
59 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |