Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
M_SBS_6
Helper V
Helper V

Total on table is incorrect

Hi, I have the following logic which totals each row correctly, but the grand total is way out, and I have no idea why. Any idea why this could be, please? 

 

Value =

if(apps[spend] <=300000, apps[spend] * apps[300_int_pc],

 

if(apps[spend] >300000 && apps[spend] <=400000, apps[spend] * apps[400_int_pc],

 

if(apps[spend] >400000 && apps[spend] <=500000, apps[spend] * apps[500_int_pc],

 

if(apps[spend] >500000, apps[spend] * apps[500over_int_pc],0))))

 

1 ACCEPTED SOLUTION
v-yalanwu-msft
Community Support
Community Support

Hi, @M_SBS_6 ;

Are [300_int_pc],[400_int_pc],[500_int_pc],500over_int_pc],  measure? I tested this funtion by a simple example.and when this dax apply into my column. the total is right.

AilsaTao_0-1661222312240.png

The final show:

AilsaTao_1-1661222333906.png

If the above one can't help you get the desired result, please provide some sample data in your tables (exclude sensitive data) with Text format and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. You can refer the following link to upload the file to the community. Thank you.

How to upload PBI in Community


Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
v-yalanwu-msft
Community Support
Community Support

Hi, @M_SBS_6 ;

Are [300_int_pc],[400_int_pc],[500_int_pc],500over_int_pc],  measure? I tested this funtion by a simple example.and when this dax apply into my column. the total is right.

AilsaTao_0-1661222312240.png

The final show:

AilsaTao_1-1661222333906.png

If the above one can't help you get the desired result, please provide some sample data in your tables (exclude sensitive data) with Text format and your expected result with backend logic and special examples. It is better if you can share a simplified pbix file. You can refer the following link to upload the file to the community. Thank you.

How to upload PBI in Community


Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

amitchandak
Super User
Super User

@M_SBS_6 , Push ar row level

 

Sumx(apps ,

if(apps[spend] <=300000, apps[spend] * apps[300_int_pc],

 

if(apps[spend] >300000 && apps[spend] <=400000, apps[spend] * apps[400_int_pc],

 

if(apps[spend] >400000 && apps[spend] <=500000, apps[spend] * apps[500_int_pc],

 

if(apps[spend] >500000, apps[spend] * apps[500over_int_pc],0)))) )

 

or you have uses values, Summarize to group it

refer https://www.youtube.com/watch?v=ufHOOLdi_jk

 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Thanks for your suggestion, but unfortunately, I still get the incorrect total amount. 

I have watched the video in the link that you sent, still not completely clear as I'm so new to Power BI.

 

Do I essentially need to include HASONEFILTER somewhere into this logic? 

@M_SBS_6 ,
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.