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!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
Hi Team,
I am trying to comparing the current vs Previous year completed values but while writing below dax always returing the same values. How to fix the issues as expected result below. I need unique values for month wise. Please find the below dax expressions and expected result in below.
current_year = CALCULATE([Completed(#)],FILTER(Table1,YEAR(Table1[Year]=YEAR(TODAY()))))
Previous Year1 = var Previous_year= YEAR(TODAY()) return CALCULATE([Completed(#)],FILTER('Table1',YEAR(Table1[Year])=Previous_year -1))
It's returing the values by using above dax.
Expected result is below like this.
Hi @sreddy47652 ,
Can you provide some sample data or share your file, please? 🙂
Thanks!
/Tom
https://www.tackytech.blog/
https://www.instagram.com/tackytechtom/
Did I answer your question❓➡️ Please, mark my post as a solution ✔️ |
Also happily accepting Kudos 🙂 |
Feel free to connect with me on LinkedIn! | |
#proudtobeasuperuser | |
Hi @sreddy47652 ,
I think you are missing the removal of the filter, i.e. by adding an ALL() to your code. Could you try this one?
CALCULATE([Completed(#)], ALL ('Table1'), FILTER('Table1',YEAR(Table1[Year])=Previous_year -1))
Let me know if this helps 🙂
/Tom
https://www.tackytech.blog/
https://www.instagram.com/tackytechtom/
Did I answer your question❓➡️ Please, mark my post as a solution ✔️ |
Also happily accepting Kudos 🙂 |
Feel free to connect with me on LinkedIn! | |
#proudtobeasuperuser | |
@tackytechtom I tried with this too but it's giving me same results for above and its alwas displaying duplicated values for across all.
Hi @sreddy47652 ,
Thanks for sharing the file! Now I can see the problem. In Power Query there were some changes made so the format was altered to a "special currency design":
PBI has difficulties to translate that back to a number and the only way it can deal with that format is by using it as a texst data type. I could not see the original data in your pbix since it was pointing to csv file, but it seems like you should come further by removing the "Replaced Value" steps:
Also, it appears like you will be having the same issue for the Valuation attribute. So remove the replacing steps and try to change the data type to number. If that does not work either you might need to remove all commas and dollar signs so that there are only numbers in your column.
Let me know if this works 🙂
/Tom
https://www.tackytech.blog/
https://www.instagram.com/tackytechtom/
Did I answer your question❓➡️ Please, mark my post as a solution ✔️ |
Also happily accepting Kudos 🙂 |
Feel free to connect with me on LinkedIn! | |
#proudtobeasuperuser | |
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.