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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

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
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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