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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
bartus1
Helper I
Helper I

Matrix - put 0 value in empty cell. ISBLANK/Blank() fail on true part.

I am displaying counts per category for people in matrix.  All works fine, but empty cells(columns) don't show up.

 

I've been trying to use IF/ISBLANK to remedy this but the empty=true never works.  All still displays fine for empty=false.

 

My statement:

 

actualCount = IF(ISBLANK(COUNTA(dOA[Category])), 0, counta(dOA[Category]))

or

actualCount = IF(ISBLANK(COUNTA(dOA[Category])), "zero", counta(dOA[Category]))

 

The conts display properly, but blanks never get replaced by 0/zero

 

Any ideas?  Thanks.

 

 

 

 

6 REPLIES 6
Anonymous
Not applicable

try count > 0 in a measure?

 

wat?

I think he meant something like this:

Var _count = counta(dOA[Category])
Return IF( _count > 0, _count, 0)
Anonymous
Not applicable

@justinh thanks or the clarification

CrisYan
Resolver III
Resolver III

Try this measure:

 

actualCount = COUNTA(dOA[Category])+0

Regards!

^Thanks.  It did not change anything.  Empty cells have nothing in them.

 

counts.PNG

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors