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 everyone
I have been stuck on this issue for a few hours and really can't seem to fix it. Any help would be greatly appreciated.
DateDim Table
Deals Table
I have a measure called "Average Cost" which is the Total Cost / Total number of deals. This measure works as expected and can be filtered by whichever month has been selected. My issue is when I try to create a measure for Average cost Last month. To do this I have created a measure called PreviousDate
PreviousDate measure - This value is generated depending on whatever is selected in the filter. For example I have currently selected May 2022, so the measure shows 2022-04
I am then trying to filter the Deals table, where the YearMonth Column = Previous Month measure. See below
What I have tried
Solved! Go to Solution.
@Kurt4597 , Find the attached file after signature
@Kurt4597 , Assume you date table is at level of year month
Create Rank on Year month , a new column
Month Rank = RANKX(all('Date'),'Date'[YearMonth],,ASC,Dense)
You can get measures
This Month = CALCULATE(sum('Table'[Qty]), FILTER(ALL('Date'),'Date'[Month Rank]=max('Date'[Month Rank])))
Last Month = CALCULATE(sum('Table'[Qty]), FILTER(ALL('Date'),'Date'[Month Rank]=max('Date'[Month Rank])-1))
Decode Time Intelligence, DATESMTD, DATESQTD, DATESYTD, Week On Week, Week Till Date, Custom Period on Period,
Custom Period till date: https://youtu.be/aU2aKbnHuWs&t=145s
Thank you for the help, but the issue is still present. The measures you have created also give BLANK results
@Kurt4597 , Find the attached file after signature
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 | |
105 | |
79 | |
68 | |
63 |
User | Count |
---|---|
148 | |
107 | |
106 | |
82 | |
70 |