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

Hide matrix rows without affecting values

Hi,

 

Is there a way I can hide rows in a matrix without affecting the value? Or get my measures to ignore the visual filters?

Capture.PNG

Context: I only want to see suppliers which have failed but when I set 'failed' to 'is not blank' in a visual filter, it takes out the highlighted row, resulting in the 'failed' column, the 'PO Documents' column and the 'Posted Documents' column all having the same value. I want to keep the totals the same, but hide this blank row, can it be done? If this can only be done in a table, then that's fine, as long as it works.

 

The code I've used to get 'PO Documents' and 'Posted Documents' is correct as I have the correct values, but the table currently shows lots of blank rows as pictured above where there aren't any failure reasons ('Currency Issue', 'No Receipts', 'Supplier Mismatch'). My Code is as follows.

 

Failed = 
CALCULATE(
    COUNTA(IMSDocuments[DocumentId]), 
    FILTER(IMSDocuments, IMSDocuments[PostingStatusId] = "6"),
    FILTER(IMSDocuments, IMSDocuments[POProcess] = TRUE),
    FILTER(IMSDocuments, ISBLANK(IMSDocuments[FirstAutoMatchFailureCode]) = FALSE)
)
PO Documents = 
CALCULATE(
    COUNTA(IMSDocuments[DocumentId]),
    FILTER(IMSDocuments, IMSDocuments[PostingStatusId] = "6"),
    FILTER(IMSDocuments, IMSDocuments[POProcess] = TRUE)
)
Posted Documents = 
CALCULATE(
    COUNTA(IMSDocuments[DocumentId]),
    FILTER(IMSDocuments, IMSDocuments[PostingStatusId] = "6")
)

So each time there is one less filter on the column.

 

Any help is really appreciated!

 

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

@Anonymous ,

 

You may try ISINSCOPE.

Measure =
IF (
    ISINSCOPE ( Table1[Column1] ),
    SUM ( Table1[Column2] ),
    CALCULATE ( SUM ( Table1[Column2] ), ALL ( Table1[Column1] ) )
)
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

1 REPLY 1
v-chuncz-msft
Community Support
Community Support

@Anonymous ,

 

You may try ISINSCOPE.

Measure =
IF (
    ISINSCOPE ( Table1[Column1] ),
    SUM ( Table1[Column2] ),
    CALCULATE ( SUM ( Table1[Column2] ), ALL ( Table1[Column1] ) )
)
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.

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