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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
LABrowne
Helper II
Helper II

DAX: How to register blank values as zero

Hi there,

 

I am currently working on a different formulas within my table on Power BI.

 

CALCULATE(SUM(OrderTable[Amount]),OrderTable[OrderTypeId] = 22 || OrderTable[OrderTypeId] = 24, OrderTable, OrderTable[IsDeleted] = False, OrderStatus[OrderStatusId] <> 7)
 
This works in adding up certain types of orders, doesn't sum deleted orders and removes orders that were cancelled.
 
The problem is sometimes it is returning blank values which is correct but how can I say if there values/sum ISBLANK = $0.00?
 
Any advice would be great!
 
Kind regards,
Luke
1 ACCEPTED SOLUTION
Arpitb12
Helper I
Helper I

You can use the IF and ISBLANK functions in Power BI to conditionally display "$0.00" when the result is blank. 
Result = VAR TotalAmount = CALCULATE( SUM(OrderTable[Amount]), OrderTable[OrderTypeId] = 22 || OrderTable[OrderTypeId] = 24, OrderTable[IsDeleted] = False, OrderStatus[OrderStatusId] <> 7 ) RETURN IF( ISBLANK(TotalAmount), "$0.00", TotalAmount )

View solution in original post

3 REPLIES 3
Arpitb12
Helper I
Helper I

You can use the IF and ISBLANK functions in Power BI to conditionally display "$0.00" when the result is blank. 
Result = VAR TotalAmount = CALCULATE( SUM(OrderTable[Amount]), OrderTable[OrderTypeId] = 22 || OrderTable[OrderTypeId] = 24, OrderTable[IsDeleted] = False, OrderStatus[OrderStatusId] <> 7 ) RETURN IF( ISBLANK(TotalAmount), "$0.00", TotalAmount )

Thank you a lot!

Jihwan_Kim
Super User
Super User

Hi,

Please check the link down below, and try to use it with your formula.

I hope this helps.


COALESCE function (DAX) - DAX | Microsoft Learn


If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.