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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Anonymous
Not applicable

Need count for matrix non zero values

Hi Team,

Please find the screenshot below, the visual used is matrix. Now I nee dto have count of all non zero values as mentioned in figure, Kindly help . Thsi can be another visual or part of same table.

 

Thanks

SwapnilB2F40355.PNG

1 ACCEPTED SOLUTION
v-chuncz-msft
Community Support
Community Support

@Anonymous,

 

You may refer to the following measure.

Measure =
IF (
    HASONEVALUE ( Table1[Date] ),
    SUM ( Table1[Qty] ),
    COUNTROWS (
        FILTER ( VALUES ( Table1[Date] ), CALCULATE ( SUM ( Table1[Qty] ) ) > 0 )
    )
)
Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

6 REPLIES 6
v-chuncz-msft
Community Support
Community Support

@Anonymous,

 

You may refer to the following measure.

Measure =
IF (
    HASONEVALUE ( Table1[Date] ),
    SUM ( Table1[Qty] ),
    COUNTROWS (
        FILTER ( VALUES ( Table1[Date] ), CALCULATE ( SUM ( Table1[Qty] ) ) > 0 )
    )
)
Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
ChrisMendoza
Resident Rockstar
Resident Rockstar

hello @Anonymous,

 

Try something like:

 

as a calculated column:

IF Statement = IF(Table2[Qty]<=0,BLANK(),1)

as a measure:

Count IFs = COUNT(Table2[IF Statement]) 

// SUM should work as well.

 

1.PNG






Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

Proud to be a Super User!



Anonymous
Not applicable

But if I want to put same in same matrix as last column then how would I do it ?As If I put this in column it creates multiple columns with same value

Yeah, that's why it's in another visual per your statement where you said it can be in another visual.






Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

Proud to be a Super User!



Anonymous
Not applicable

Can I have count in matrix as only last column?

Anonymous
Not applicable

any inputs ?

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

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.