Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi Folks,
Hope you can help.. I've tried a few different things and can't get this one to work..
So I have a transactions table linked to a dates table...
I'm trying to work out the "Current month spend" .. where the current month would be the month I have the most recent transaction for.
So for FY23, LASTMONTH = 5 (May)
For FY22 , LASTMONTH = 6 (June)
My "Current Month SPend" calculation is:
Which gives the following result (and is wrong!) notice the "Kids activities" category is showing a value which is incorrect
If I hard code the month value into the Current Month Spend then it works perfectly:
See the categories that don't have transactions in May are showing as blank..
What am I doing wrong?
Thanks for any feedback,
Asha
Solved! Go to Solution.
ALLEXCEPT is a rather blunt instrument. Try using the more gentle REMOVEFILTERS.
Please show the definition of LASTMONTH
Hello, thanks for your reply... LASTMONTH is..
Correct. Change that measure by removing the category filter.
Nearly have it!
So I changed LASTMONTH to be:
ALLEXCEPT is a rather blunt instrument. Try using the more gentle REMOVEFILTERS.
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 11 | |
| 7 | |
| 5 | |
| 5 | |
| 3 |