+ Reply to Thread
Results 1 to 7 of 7

How Many in column B for each in Column A

Hybrid View

  1. #1
    Valued Forum Contributor
    Join Date
    12-02-2009
    Location
    Austin, Tx
    MS-Off Ver
    Office 365 64-Bit, 2108, build 14326.21018
    Posts
    4,065

    How Many in column B for each in Column A

    My brain is frazzled and I can't think my way through this. In a nutshell; Vendor supplies us with a list of employee names that the vendor did services for. Vendor can't spell, so the names he supplies are all over the place. In my example, I have the actual name in column A, and the vendor supplied names in column B. (this is just a sample; actual list is about 10K more employees). What I want to know is:
    • (First)how many UNIQUE derivatives exist in column B for each name in column A?
    • (Second)Which actual name has the most derivatives?
    Sorry to bring this to you, but my brain is apparently on strike, 'cause I can't think this one through yet.
    I appreciate any help I can get.
    Attached Files Attached Files
    I know I'm not stupid, but I suspect I'm a lot stupider than I think I am

  2. #2
    Forum Expert
    Join Date
    10-19-2021
    Location
    Brazil
    MS-Off Ver
    Office 365 V2401 w/ Win10 Home 64 Bit
    Posts
    2,014

    Re: How Many in column B for each in Column A

    Proposed solution with Power Query.
    Attached Files Attached Files

  3. #3
    Forum Moderator
    Join Date
    01-21-2014
    Location
    St. Joseph, Illinois U.S.A.
    MS-Off Ver
    Office 365 V 2504
    Posts
    13,742

    Re: How Many in column B for each in Column A

    With formula ... although with that many lines of data this may be prohibitive. In C4 and filled down this gives a count of unique derivatives for each name in column A. Since you are using Office 365 this does not have to be array entered.
    Formula: copy to clipboard
    =IF(COUNTIF($A$4:$A4,$A4)>1,"",SUM(FREQUENCY(IF($A4=$A$4:$A$92,MATCH($B$4:$B$92&"",$B$4:$B$92&"",0)),
    ROW($B$4:$B$92)-MIN(ROW($B$4:$B$92))+1)))
    Then the MAX
    Formula: copy to clipboard
    =MAX($C:$C)
    Dave

  4. #4
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,466

    Re: How Many in column B for each in Column A

    Another option, if I have understood your requirement.
    Attached Files Attached Files
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  5. #5
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,466

    Re: How Many in column B for each in Column A

    Or maybe this is better.
    Attached Files Attached Files

  6. #6
    Valued Forum Contributor
    Join Date
    12-02-2009
    Location
    Austin, Tx
    MS-Off Ver
    Office 365 64-Bit, 2108, build 14326.21018
    Posts
    4,065

    Re: How Many in column B for each in Column A

    I am SO sorry. Apparently I forgot about this post (hence my frazzled brain in the first post). I just this minute came back to it. Please accept my apologies.

    DJunqueria and FlameRetired, I really appreciated both your efforts, but the results aren't what I expected. For instance, "Akiri,Brigid O" is "Our" name. That name appears 19 times. But the vendor gave us 17 different names for this person:"Brigid" and "Brigid O Akiri" were both used twice, so the correct answer would be 17 unique names, not 19.

    TMS, both of your attempts were spot on, but I liked the second better. Thanks for showing me a way to eat my elephant. I haven't yet tried it on my full data set yet, but that's my next project. I'll let you know how it works.

  7. #7
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,466

    Re: How Many in column B for each in Column A

    You're welcome. Thanks for the rep.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 7
    Last Post: 08-09-2015, 05:07 PM
  2. Compare multiple columns (column A,column B,Column C) and return value (Column D)
    By john008 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-21-2015, 08:24 AM
  3. [SOLVED] Delete Cell Numbers of Column B From Column A (Column B Small and Column A too big)
    By it_electronics2000 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 04-09-2012, 08:56 AM
  4. [SOLVED] Delete Cell Numbers of Column B From Column A (Column B Small and Column A too big)
    By it_electronics2000 in forum Excel General
    Replies: 4
    Last Post: 04-07-2012, 09:14 AM
  5. [SOLVED] Delete Cell Numbers of Column B From Column A (Column B Small and Column A too big)
    By it_electronics2000 in forum Excel - New Users/Basics
    Replies: 1
    Last Post: 04-06-2012, 11:19 AM
  6. [SOLVED] Delete Cell Numbers of Column B From Column A (Column B Small and Column A too big)
    By it_electronics2000 in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 04-06-2012, 11:18 AM
  7. [SOLVED] Delete Cell Numbers of Column B From Column A (Column B Small and Column A too big)
    By it_electronics2000 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 04-06-2012, 11:13 AM

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