+ Reply to Thread
Results 1 to 4 of 4

Finding rows with duplicates in two columns

  1. #1
    Registered User
    Join Date
    07-10-2008
    Location
    Texas
    Posts
    12

    Finding rows with duplicates in two columns

    Can someone please help me with a formula or vb code to find all of the rows that match another row on two columns? I need to be able to delete all duplicate rows, but they're only duplicates if two columns match. For example

    Please Login or Register  to view this content.
    Only rows 1 and 5 would match.

  2. #2
    Forum Expert
    Join Date
    01-15-2007
    Location
    Brisbane, Australia
    MS-Off Ver
    2007
    Posts
    6,591
    Hi

    C1: =IF(SUMPRODUCT(--($A$1:$A$5=A1),--($B$1:$B$5=B1))>1,"Duplicate","")

    Copy down to C5.

    HTH

    rylo

  3. #3
    Registered User
    Join Date
    06-25-2008
    Posts
    6
    Hi,

    I was not able to find any formula that would help delete the duplicates.
    However, I have written a VBA macro that would attain the same result.

    You can find it in the attached workbook.
    Please execute it on a variety of data (only values in Columns A and B will be compared) and let me know if it helps.

    Regards
    Attached Files Attached Files

  4. #4
    Registered User
    Join Date
    07-10-2008
    Location
    Texas
    Posts
    12
    Thanks guys! That helped a lot.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1