Forum Discussion

ianwuk's avatar
ianwuk
Helper III
9 years ago
Solved

How to show data when only one column data changes?

I have data that looks like this:

 

License               ID         Date

12334                 123      7/7/17

45434                 456      6/7/17

67834                 123      5/7/17

 

As you can see, the same license key has two different ID numbers on two different dates (in UK format).

 

How can I show only those ones in a report? So only when the same license has one or more different ID?

 

Thanks.

 

  • When you first import you data into PowerBI, choose EDIT instead of OK.  Or you can hit 'Edit Queries' from the Home Tab.  This takes you into the Query Editor.  From here, highlight your LicenseKey column, and choose 'Keep Rows' 'Keep Duplicates' from the ribon.  This will only keep rows with duplicate values.  Just make sure LicenseKey is clicked and highlighted first.

     

    FOrrest

7 Replies

    • ianwuk's avatar
      ianwuk
      Helper III

      Thanks for this fhill!

       

      I will give it a try next week and update here if I have any more questions.

      • Phil_Seamark's avatar
        Phil_Seamark
        Microsoft Employee

        Hi ianwuk

         

        Please add the following calculated column to your table (and adjust the name of the table to yours)

         

        License Duplicates = CALCULATE(
                                    DISTINCTCOUNT('Table1'[License]),
                                    FILTER(
                                        ALL('Table1'),
                                        'Table1'[ID] = EARLIER(Table1[ID])
                                        )
                                       )

        This will return a number that indicates how many other distinct licenses share the same ID which you can use in a filter.