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
Anonymous
Not applicable

Show 0 for empty cells in table

I am wondering if there is something similar to excel/pivot table"For empty cells show" (see picture below) in Power BI table/matrix visuals?

I know that is it possible to solve using DAX (replacing empty with 0 in the measure calculation) but I have a lot of measures that would need to be changed in that case

 

joakimfe_0-1625138805721.png

 

2 ACCEPTED SOLUTIONS
Greg_Deckler
Super User
Super User

@Anonymous No, you would have to solve that in DAX. There is a "Show values with no data" but that just shows blanks if that is what the measure returns.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Power BI Cookbook Third Edition (Color)

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

v-luwang-msft
Community Support
Community Support

Hi @Anonymous ,

Adjust the corresponding measures, which have null values that you want to transform to 0:

 

newmeasure= var beforemeasure=(here is the measure you used before)
return if(beforemeasure=blank(),0,beforemeasure)

 

 

Wish it is helpful for you!

Best Regards

Lucien

View solution in original post

3 REPLIES 3
v-luwang-msft
Community Support
Community Support

Hi @Anonymous ,

Adjust the corresponding measures, which have null values that you want to transform to 0:

 

newmeasure= var beforemeasure=(here is the measure you used before)
return if(beforemeasure=blank(),0,beforemeasure)

 

 

Wish it is helpful for you!

Best Regards

Lucien

Greg_Deckler
Super User
Super User

@Anonymous No, you would have to solve that in DAX. There is a "Show values with no data" but that just shows blanks if that is what the measure returns.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Power BI Cookbook Third Edition (Color)

DAX is easy, CALCULATE makes DAX hard...

Could use mwhite space

ivangarcialeon_0-1677238201370.jpeg

Then create a measure with the function

SELECTEDVALUE, this function returns the value if the columnName context has been filtered to a single different value. Otherwise, it returns alternateResult. (in this case we will assign a 0 to the alternative value)

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.