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

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
wooand
Helper II
Helper II

Change calculationss according to a name within a column.

This is proving difficult:

 

I have a measure which is SUM(Sheet1[amount1]/SUM(Sheet1[amount2)*10000.  This works just fine, but for one name in the column, the amounts involved are negative which of course creates a positive result.  I need to show a negative result so I was hoping to simply use an IF function to flip the calc when it encounters the 'negative' name, giving me a negative result where required in the report.  In Excel creating an IF function is easy, and works, and I can do it as a calculated column in DAX, but I need it as a measure in order to be able to show everything in a single column with the correct sign.

 

Any clues as to how to build this correctly?

4 REPLIES 4
v-caliao-msft
Microsoft Employee
Microsoft Employee

@wooand,

 

Could you pleas show us some sample data? Generally, we can use IF function to check if it's a negative value. In your scenario, please elaborate your expected with sample data, so that we can make further analysis.

 

Regards,

Charlie Liao

Thanks for taking a look Charlie, but I've built a way around.  I really don't think it's possible any other way in fact!

Would you please post your solution so we can all benefit from it

I did the most basic thing possible.  I calculated the equation to create the negative value I wanted and then just set up a new visual with that calculation in.  I can't create a list with all the values together, bnut rather I now have two lists, one with positive values and one with negative.  It's inelegant and messy, but that's life for me...

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.

Top Solution Authors
Top Kudoed Authors