Forum Discussion

Dbjerring's avatar
Dbjerring
Regular Visitor
9 years ago
Solved

Remove duplicates based on values from multiple cells

Hi Community,   We have dataset based on logs - here we would like to create a new column with a true/false value if the line is a duplicate. We have UserID, LogTimeDate, LogTime, and number of lo...
  • v-chuncz-msft's avatar
    v-chuncz-msft
    9 years ago

    Dbjerring,

     

    You could modify the formula as shown below.

    IsDuplicate =
    IF (
        COUNTROWS (
            FILTER (
                Logs,
                Logs[LogCNumber] = EARLIER ( Logs[LogCNumber] )
                    && Logs[LogTime.1] = EARLIER ( Logs[LogTime.1] )
                    && Logs[LogID] < EARLIER ( Logs[LogID] )
            )
        )
            > 0,
        TRUE (),
        FALSE ()
    )