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
OSS
Helper III
Helper III

total sum problem

Dear all

I want to calculate column with condition. My condition is 

Exp = if([Income]>0,[Income],0). However at the end, the sum of the columns doesn't change. I need correct sum for the exp column in order to calculate weight of each customer.
Please help me with this issue

tax sample.PNG

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

Hi @OSS 

Create measures

Measure = IF(SUM(Sheet4[income])>0,SUM(Sheet4[income]),0)

Measure 2 = SUMX(ALL(Sheet4),[Measure])

Measure 3 = IF(HASONEVALUE(Sheet4[customer no]),[Measure],[Measure 2])

2.png

 

Best Regards
Maggie

 

Community Support Team _ Maggie Li
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

1 REPLY 1
v-juanli-msft
Community Support
Community Support

Hi @OSS 

Create measures

Measure = IF(SUM(Sheet4[income])>0,SUM(Sheet4[income]),0)

Measure 2 = SUMX(ALL(Sheet4),[Measure])

Measure 3 = IF(HASONEVALUE(Sheet4[customer no]),[Measure],[Measure 2])

2.png

 

Best Regards
Maggie

 

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

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!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.