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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
NBOnecall
Helper V
Helper V

Measure to Show Duplicates in a Matrix Visual

Hi, 

 

I have the below data in a matrix and I would like to only show the duplicates. 

 

I have tried to use this formula,

 

Measure = CALCULATE(counta('ns SettlementItemPrice'[FixedSKU]),ALLEXCEPT('ns SettlementItemPrice','ns SettlementItemPrice'[FixedSKU])),
 
 

but I feel like I am missing a peice as my results are not what I was expecting. 

 

The Image below is my results with that measure. I want the measure to output 2, for the two rows that the FixedSKU shows up in the visualization. 

Matrix Only show duplicates.png

Thanks!

 

1 ACCEPTED SOLUTION

Hi @NBOnecall ,

 

Create the following measure:

CountRows = 
MAXX (
    ADDCOLUMNS (
        SUMMARIZE ( SKU; SKU[FixedSKU]; SKU[Fee]; SKU[Price] );
        "CountRows"; CALCULATE (
            COUNTROWS ( SUMMARIZE ( SKU; SKU[FixedSKU]; SKU[Fee]; SKU[Price] ) );
            ALLEXCEPT ( SKU; SKU[FixedSKU] )
        )
    );
    MAX ( [CountRows] )
)

Then add it to the filter pane and select all values different from 1.

 

See attach PBIX.

 

Regards,

MFelix


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



View solution in original post

4 REPLIES 4
MFelix
Super User
Super User

Hi @NBOnecall ,

 

The use of the ALLEXCEPT formula take out all the filter context from your measure except the columns you place in it, in this case believe that is the problem with your measure because you are placing in the EXCEPTION the FixedSKU column so the context for each row is kept.

 

Don't know the details of your model but you should use an ALL or ALLSELECTED syntax in order to get the count of the two rows.

 

Can you please share some sample data and expected result?

 

Regards,

MFelix


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



@MFelix 

So please see the first picture, this is the raw data. 

Table of Data.PNG

These would be the visualizations as the table of data is being summed on the quantity with a Measure to count how many lines are in the visualization witht the same SKU. 

Expected Output.PNG

The expected out put would be the final image, after filtering out the rows with 1 count for the measure. 

With filter to remove Count of 1.PNG

Thanks. 

Hi @NBOnecall ,

 

Create the following measure:

CountRows = 
MAXX (
    ADDCOLUMNS (
        SUMMARIZE ( SKU; SKU[FixedSKU]; SKU[Fee]; SKU[Price] );
        "CountRows"; CALCULATE (
            COUNTROWS ( SUMMARIZE ( SKU; SKU[FixedSKU]; SKU[Fee]; SKU[Price] ) );
            ALLEXCEPT ( SKU; SKU[FixedSKU] )
        )
    );
    MAX ( [CountRows] )
)

Then add it to the filter pane and select all values different from 1.

 

See attach PBIX.

 

Regards,

MFelix


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



@MFelix 

 

How would I go about if I want to omit data if it has a $0.00 Fee from the measure?

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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