+ Reply to Thread
Results 1 to 9 of 9

Comma Separated Cell Values to Column of Unique Cell Values

  1. #1
    Registered User
    Join Date
    10-08-2012
    Location
    BOS
    MS-Off Ver
    Excel 2011 Mac
    Posts
    15

    Comma Separated Cell Values to Column of Unique Cell Values

    step 1
    i have one column of data. there are currently ~10k rows, but this will increase over time. each row has either a single value (example: pepsi) or a comma separated value (google,samsung) with up to 6 commas. instead of the rows looking like this:

    pepsi
    google,samsung
    coca-cola


    i want them to look like this in one column (preferably via a formula):

    pepsi
    google
    samsung
    coca-cola


    step 2
    i would like the above output to be a unique, alphabetized list. i think i have a formula that will work for this, but if there is a way to do this all at once, i'm all ears. again, i'd prefer a formula.

    any help is appreciated on either of these steps! i've been trying this a few different ways, and i'm not sure this is the best one.
    Last edited by Nuggetross; 04-02-2014 at 01:21 PM.

  2. #2
    Registered User
    Join Date
    10-08-2012
    Location
    BOS
    MS-Off Ver
    Excel 2011 Mac
    Posts
    15

    Re: Comma Separated Cell Values to Column of Unique Cell Values

    i've found some formulas using offset or index that are close...

  3. #3
    Registered User
    Join Date
    10-08-2012
    Location
    BOS
    MS-Off Ver
    Excel 2011 Mac
    Posts
    15

    Re: Comma Separated Cell Values to Column of Unique Cell Values

    *bump*

    any ideas out there, internet?

  4. #4
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: Comma Separated Cell Values to Column of Unique Cell Values

    Please see attached file with formula entered in B2 and dragged across and down.
    Attached Files Attached Files
    If you like my answer please click on * Add Reputation
    Don't forget to mark threads as "Solved" if your problem has been resolved

    "Nothing is so firmly believed as what we least know."
    --Michel de Montaigne

  5. #5
    Registered User
    Join Date
    10-08-2012
    Location
    BOS
    MS-Off Ver
    Excel 2011 Mac
    Posts
    15

    Re: Comma Separated Cell Values to Column of Unique Cell Values

    that's good, but i need all of the data in a single column. so literally like this:

    pepsi
    google
    samsung
    coca-cola


    apologies if my ask was unclear.

  6. #6
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: Comma Separated Cell Values to Column of Unique Cell Values

    I couldn't come up with one formula solution for this task. In the attached sheet you will see an alternative where data first extracted as it was suggested in first post and then combined in one column (see column K for formula).
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    10-08-2012
    Location
    BOS
    MS-Off Ver
    Excel 2011 Mac
    Posts
    15

    Re: Comma Separated Cell Values to Column of Unique Cell Values

    step 1 complete! this is awesome. thank you.

    any way we can integrate something like this formula for getting uniques/alphabetizing for step 2? i've used it before with success. but for some reason, i'm getting some blanks (not ideal):

    {=IF(I1="","",IF(ISERROR(INDEX($I$2:$I$1000,MATCH(0,COUNTIF($I$2:$I$1000,"<"&$I$2:$I$1000)-SUM(COUNTIF($I$2:$I$1000,"="&I$1:I1)),0)))=TRUE,"",INDEX($I$2:$I$1000,MATCH(0,COUNTIF($I$2:$I$1000,"<"&$I$2:$I$1000)-SUM(COUNTIF($I$2:$I$1000,"="&I$1:I1)),0))))}

  8. #8
    Forum Guru AlKey's Avatar
    Join Date
    07-20-2009
    Location
    Lakeland, FL USA
    MS-Off Ver
    Microsoft Office 2010/ Office 365
    Posts
    8,903

    Re: Comma Separated Cell Values to Column of Unique Cell Values

    Copy and paste values from Column K into this attached macro-enabled sheet in A2 and press the button. It will extract unique values in alphabetical order.
    Attached Files Attached Files

  9. #9
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Comma Separated Cell Values to Column of Unique Cell Values

    It is not possible to do all that you want with a single formula in one column.

    You could get this list with one formula:

    pepsi
    google
    samsung
    coca-cola

    Then, you would need another formula to get the sorted list:

    coca-cola
    google
    pepsi
    samsung

    However:

    there are currently ~10k rows, but this will increase over time.
    The formulas needed to do this are very calculation intensive and on 10k+ rows of data it might negatively impact the performance of your file.
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

+ 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. [SOLVED] Compare comma separated values in a cell to a list
    By SMB in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 10-03-2019, 01:10 AM
  2. [SOLVED] Macro to give the count of unique values after comparing the comma separated values
    By Manish_Gupta in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-03-2014, 12:41 AM
  3. [SOLVED] Extracting information from a comma separated list of values in one cell
    By cardiff in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 09-11-2012, 09:17 PM
  4. Replies: 3
    Last Post: 01-13-2012, 08:20 AM
  5. Resolved >>> Comma separated values in a cell
    By usr789 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 10-25-2007, 08:36 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