+ Reply to Thread
Results 1 to 7 of 7

Eliminate Dupes from a list, multiple lists...

  1. #1
    Registered User
    Join Date
    05-22-2009
    Location
    Southampton, NY
    MS-Off Ver
    Excel 2003
    Posts
    29

    Eliminate Dupes from a list, multiple lists...

    Hello all! Long time linger-er.. First time registering, and posting!

    So, I know there has to be some sort of great way to eliminate dupes without paying someone to do it.. No?

    I have a mailing list, 1 list of about 17k, and multiple others ranging up to about 1-5k.. They are school names, and I only want 1 of each.. They had unique persons names on them, but I no longer need those...

    What is the best way to go through and purge the dupes?

    I appreciate all your help, as you are aiding my Father and I's business, that was sabotaged beyond belief by our previous employee...

  2. #2
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Eliminate Dupes from a list, multiple lists...

    DeleteDupe macros are pretty common. The only thing we need is info about WHICH column in your sheet has the values that are to be evaluated as "duplicate" or not.

    Also, posting up a sample excerpt of your data is always helpful. Click on GO ADVANCED and use the paperclip icon to attach a sample workbook.
    _________________
    Microsoft MVP 2010 - Excel
    Visit: Jerry Beaucaire's Excel Files & Macros

    If you've been given good help, use the icon below to give reputation feedback, it is appreciated.
    Always put your code between code tags. [CODE] your code here [/CODE]

    ?None of us is as good as all of us? - Ray Kroc
    ?Actually, I *am* a rocket scientist.? - JB (little ones count!)

  3. #3
    Registered User
    Join Date
    05-22-2009
    Location
    Southampton, NY
    MS-Off Ver
    Excel 2003
    Posts
    29

    Re: Eliminate Dupes from a list, multiple lists...

    Thanks for the response! Ok, yes.. Here is the sample.. Would it be possible for me to designate the columns, changing the macro as necessary?

    Let me know if you need anything else.


    Thanks again,

    Sean
    Attached Files Attached Files

  4. #4
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Eliminate Dupes from a list, multiple lists...

    Please describe the logic you want employed to determine duplication...just column A, B, A&B, A&B&M...you get the idea. Make it clear.

  5. #5
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Eliminate Dupes from a list, multiple lists...

    The most basic deletedupes loop goes by a unique qualifying value, such as your column M appears to be. As such, this may do the job for you:
    Please Login or Register  to view this content.
    I've highlighted in red the only part you would need to adjust to select a different single column to evaluate by.
    Last edited by JBeaucaire; 05-22-2009 at 02:11 PM. Reason: CORRECTED COUNTIF formula

  6. #6
    Registered User
    Join Date
    05-22-2009
    Location
    Southampton, NY
    MS-Off Ver
    Excel 2003
    Posts
    29

    Re: Eliminate Dupes from a list, multiple lists...

    Well, I guess the school name would be the enough of a unique identifier.. Right?

  7. #7
    Forum Expert JBeaucaire's Avatar
    Join Date
    03-21-2004
    Location
    Bakersfield, CA
    MS-Off Ver
    2010, 2016, Office 365
    Posts
    33,492

    Re: Eliminate Dupes from a list, multiple lists...

    If you think so, then fine. The macro I've posted above in post #5 is to delete rows based on a single column choice. In that one I chose "M" because it appears to be a unique customer code.

    If you change all the "M"s to "D"s it would work off that column. I ran it with "M" and "D" as the column choice and it appears to give the exact same results. Up to you to change it if you wish. This is ready to use once you settle on which column and insert the macro into a standard module.
    1. Open up your workbook.
    2. Get into VB Editor (Press Alt+F11)
    3. Insert a new module (Insert > Module)
    4. Copy and Paste in your code (given above)
    5. Get out of VBA (Press Alt+Q)
    6. Save your sheet.
    Then press Alt-F8 and select the DeleteDupesByCountif macro.

+ 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