+ Reply to Thread
Results 1 to 7 of 7

Compare columns A & B, list unique rows of column B in column C

  1. #1
    Registered User
    Join Date
    05-03-2014
    Location
    Pittsburgh. PA
    MS-Off Ver
    Excel 2010
    Posts
    3

    Compare columns A & B, list unique rows of column B in column C

    This sounds like it should be relatively easy to do, but so far I am not having any luck. I would like to compare column a and b, then list the unique rows in column b in a third column. I have looked at Advanced Filtering, but keep getting the dreaded "Extract range has a missing or illegal field name" message. Thanks in advance for any and all advice.

  2. #2
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: Compare columns A & B, list unique rows of column B in column C

    This uses helper columns but it eventually gets to where you want to go:
    Attached Files Attached Files
    <---------If you like someone's answer, click the star to the left of one of their posts to give them a reputation point for that answer.
    Ron W

  3. #3
    Forum Expert icestationzbra's Avatar
    Join Date
    01-07-2004
    MS-Off Ver
    2007, 2010
    Posts
    1,421

    Re: Compare columns A & B, list unique rows of column B in column C

    single cell array formula, placed in cell F2 of newdoverman's example above, and drag-filled down:

    Please Login or Register  to view this content.
    1400
    - i.s.z -
    CSE, aka Array aka { }, formulae are confirmed with CONTROL+SHIFT+ENTER.
    Replace commas ( , ) with semicolons ( ; ) in formulae, if your locale setting demands.
    All good ideas are courtesy resources from this forum as well as others around the web.
    - e.o.m -

  4. #4
    Registered User
    Join Date
    05-03-2014
    Location
    Pittsburgh. PA
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: Compare columns A & B, list unique rows of column B in column C

    newdoverman, I appreciate the quick response. I was able to plugin my data, comparing 2000 rows to an index of 7000 rows, to your spreadsheet and was able to modify the formula in column C to identify the unique rows in column B. Forgive my beginner knowledge of Excel, but I am having difficulty modifying the formula in column F to list any more than 25 unique rows from column B.

    Here is the modified formula from C2, which seems to be working:
    =IF(COUNTIF($A$2:$A$7810,B2)>0,"",MAX($C$1:C1)+1)

    This is the modified formula from F2, which is only returning 25 unique rows from B:
    =IFERROR(INDEX($B$2:$B$2362,MATCH(E2,$C$2:$C$2362,0)),"")

    I also just noticed that column E is only enumerated to row 26 even though column C identifies 324 unique rows.

    I am sure that I am missing something simple, but as I said my untrained eye is blind tonight. Thanks, in advance for your help.

  5. #5
    Forum Contributor
    Join Date
    08-02-2012
    Location
    Pune
    MS-Off Ver
    Office 365 (Win 10)
    Posts
    489

    Re: Compare columns A & B, list unique rows of column B in column C

    Compare.zipWill this do your work?
    I use this always
    Please make the Post as solved, when you get your answer & Click * if you like my suggestion

  6. #6
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: Compare columns A & B, list unique rows of column B in column C

    Sorry for the delay in getting back to you. My internet routing to the forum was lost yesterday and it took a while to get it back. Something between me and Excelforum broke down.

    Here is a modification of the file that will go down 20000 rows.

    Again, I apologize for not responding earlier but I had no connection available.
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    05-03-2014
    Location
    Pittsburgh. PA
    MS-Off Ver
    Excel 2010
    Posts
    3

    Re: Compare columns A & B, list unique rows of column B in column C

    Quote Originally Posted by newdoverman View Post
    Sorry for the delay in getting back to you. My internet routing to the forum was lost yesterday and it took a while to get it back. Something between me and Excelforum broke down.

    Here is a modification of the file that will go down 20000 rows.

    Again, I apologize for not responding earlier but I had no connection available.
    No worries, I appreciate your help. Glad your connected again. Thanks, again.

+ 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: 8
    Last Post: 09-12-2013, 09:17 AM
  2. Compare 2 columns of data and get unique values in the 3rd column
    By Eduard in forum Excel Programming / VBA / Macros
    Replies: 30
    Last Post: 04-04-2013, 08:32 AM
  3. Merge rows according to unique IDs in column A- with multiple columns
    By inbars in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 03-26-2013, 08:03 PM
  4. [SOLVED] Compare two columns and list the unique values in 3rd column
    By jewellove in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-10-2013, 10:40 AM
  5. [SOLVED] Compare multiple column of data and list out common and unique component in adj columns
    By kuansheng in forum Excel Formulas & Functions
    Replies: 15
    Last Post: 02-01-2006, 06:55 PM

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