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 have a report that runs weekly for years. The column "Run Date" has ever unique Saturday date since it began.
Run Date Total Cost
02/03/2018 150.00
02/10/2018 200.00
02/17/2018 175.00
02/24/2018 210.00
03/03/2018 125.00
03/10/2018 175.00
I need a DAX formula to return the value for each month after finding the max date of each month. The max date for Feb is 02/24/2018 and the Total cost was 210.00. The max date for March is 03/10/2018 and the Total Cost was 175.00
Final result should be:
210.00 for Feb
175.00 for March
I tried:
Month End Inv = CALCULATE(sum(Inventory[ExtCost]),LASTDATE(DateDimension[Date]))
but of course it did not work.
Solved! Go to Solution.
HI @Anonymous
What if you take LASTDATE from Inventory Table
Month End Inv = CALCULATE ( SUM ( Inventory[ExtCost] ), LASTDATE ( Inventory[Run Date ] ) )
HI @Anonymous
What if you take LASTDATE from Inventory Table
Month End Inv = CALCULATE ( SUM ( Inventory[ExtCost] ), LASTDATE ( Inventory[Run Date ] ) )
I know this is a year old but...
Can I ask why the MAX of the Date table didn't work but the LASTDATE from the other table did? Is it to do with how MAX works with dates or did you suspect the relationships were affecting the MAX function's purpose?
I'll tell you what it would do...........it will work perfectly if I do what you suggested.
Thank you!!
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 |
---|---|
113 | |
97 | |
84 | |
67 | |
60 |
User | Count |
---|---|
150 | |
120 | |
99 | |
87 | |
68 |