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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
thmonte
Helper IV
Helper IV

Displaying 0's in a Matrix With Relationships

I have a matrix where I am displaying related locations + some calculations within.

 

In one of my calculations I sometimes get blank values and I would like these to be show as zeros but when I write a IF statement on the return it brings in ALL locations even if they have no data associated with it.

 

WITH IF DAX

 image.png

 

WITHOUT IF DAX

image.png

 

Is there anyway to not show the locations that have NO records associated with it and display the 0's?

 

PBIX Example

1 ACCEPTED SOLUTION
Anonymous
Not applicable

@thmonte,

Please check modified PBIX file which is attached below.

Regards,
Lydia

View solution in original post

5 REPLIES 5
Anonymous
Not applicable

@thmonte,

Please check modified PBIX file which is attached below.

Regards,
Lydia

so rather than the IF statement just +0 ?

Anonymous
Not applicable

@thmonte,

I also drag Location field of Target  table to Matrix rows, and filter out blank locations in visual level filter of the Matrix visual.

Regards,
Lydia

jthomson
Solution Sage
Solution Sage

Post some data and what you want the output to look like. Your "brings in all locations" comment makes no sense without context as to what you want to be shown as zero and what you want to be shown as blank


@jthomson wrote:

Post some data and what you want the output to look like. Your "brings in all locations" comment makes no sense without context as to what you want to be shown as zero and what you want to be shown as blank


 

Having a hard time attaching a .pbix - I did update my original post with photos tho.

 

 

Edit:  Also added external link to pbix

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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