Showing results for 
Search instead for 
Did you mean: 
Regular Visitor

How can I convert negative value to zero



I couldn't find a solution for this, so I really do hope that someone can support with this.

I have calculation where negative values should be converted to zero. Any ideas?

Thanks a lot,



Resident Rockstar
Resident Rockstar

Ya we can do . 


If (  measure < 0 , 0 , measure )



thats it. 


let me know if any further help.

Frequent Visitor

I am wondering if this is the optimal way or if using the function max( measure, 0) performs quicker.


(apologies for ressurecting an old thread!)

Frequent Visitor

Test if the number is negative, and if so, add the abolute value of that number.

That will give you the zero.


IF( [Number] < 0, [Number] + ABS( [Number] ), [Number] )






Responsive Resident
Responsive Resident

Have you tried adding a conditional column? See example below. Of course with your own column names. I am the first to admit that this is not very elegant, but it should work until you have a better solution.



Best - Sascha
Please always mark accepted solutions. It helps others with similar questions or problems. Thank you.

Helpful resources

Microsoft Build 768x460.png

Microsoft Build is May 24-26. Have you registered yet?

Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.

charticulator_carousel_with_text (1).png

Charticulator Design Challenge

Put your data visualization and design skills to the test! This exciting challenge is happening now through May 31st!

May UG Leader Call Carousel 768x460.png

What difference can a User Group make for you?

At the monthly call, connect with other leaders and find out how community makes your experience even better.

Power BI Release May 2022 768x460.png

Check it out!

Click here to read more about the May 2022 updates!