Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredJoin 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.
I am using an if statement to check values and it works on row level but on total it uses the total line which give wrong totals
Solved! Go to Solution.
Hi @Anonymous ,
In Power BI, the total is not simply the sum of all row values, it will also calculate by the formula.
You may consider to create a new measure by using ISINSCOP() and SUMX() function.
https://docs.microsoft.com/en-us/dax/isinscope-function-dax
https://docs.microsoft.com/en-us/dax/sumx-function-dax
measure = IF(ISINSCOPE([axis column]),[xxx %],SUMX(ALLSELECTED('table'),[xxx %]))
It will return xxx % on row level and return the sum of xxx % at total field.
Best Regards,
Jay
Hi @Anonymous ,
In Power BI, the total is not simply the sum of all row values, it will also calculate by the formula.
You may consider to create a new measure by using ISINSCOP() and SUMX() function.
https://docs.microsoft.com/en-us/dax/isinscope-function-dax
https://docs.microsoft.com/en-us/dax/sumx-function-dax
measure = IF(ISINSCOPE([axis column]),[xxx %],SUMX(ALLSELECTED('table'),[xxx %]))
It will return xxx % on row level and return the sum of xxx % at total field.
Best Regards,
Jay
HI @Anonymous ,
This is a very common issue when creating measures. Chek the following article on how to resolve this:
https://community.powerbi.com/t5/DAX-Commands-and-Tips/Dealing-with-Measure-Totals/td-p/63376
Thanks,
Pragati
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 80 | |
| 40 | |
| 31 | |
| 27 | |
| 27 |