+ Reply to Thread
Results 1 to 15 of 15

Semicolon delimited list

  1. #1
    Registered User
    Join Date
    10-01-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    11

    Semicolon delimited list

    Hi Everyone,

    I am a basic user of Excel and need some help with a semicolon delimited list.

    My data set is similar to this:

    (a) 1;2;5
    (b) 1;3;4
    (c) 2;3;5

    I understand how to covert this into columns, but what I need is a little more complex than that. Each value represents a yes/no option. I need the data broken down into 5 columns and for the values to be put into their respective columns. For example person a would have a value for columns 1,2,5 (but not the other columns), person b for columns 1,3,4 and person c for columns 2,3,5.

    Please help, this is a large dataset and I need an easy way to sort it!

  2. #2
    Forum Moderator vlady's Avatar
    Join Date
    09-22-2011
    Location
    Philippines - OLSHCO -Guimba-Nueva Ecija
    MS-Off Ver
    2021
    Posts
    4,361

    Re: Semicolon delimited list

    Moderator's Note:

    Welcome to the forum.

    I think you should post a sample workbook of what you are working so members could could think of ideas to resolved your issue.


    To attach a sample workbook. Make sure there is just enough data to make it clear what is needed. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are demonstrated, mock them up manually if needed. Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic


    Nice to have you with us.

    Regards,
    Vladimir
    I think people forget the word "THANK YOU!!!!" Do you still know it???

    There is a little star ( ADD REPUTATION ) below those person who helped you. Click it to say your "PRIVATE APPRECIATION TO THEIR EFFORT ON THEIR CONTRIBUTIONS "

    Regards,
    Vladimir

  3. #3
    Registered User
    Join Date
    10-01-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    11

    Re: Semicolon delimited list

    Thanks very much for the suggestion - also I hope I have posted this in the appropriate thread.

    I have attached an example using a cut down version of my real data. I would be really grateful if someone could help automate the process, Ihave more than 2000 cases and a bunch of different variables that need to be broken down into groups.

    Attached Files Attached Files

  4. #4
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: Semicolon delimited list

    Hi Stuart and welcome to the forum,

    See if the attached workbook solves your problem.
    Attached Files Attached Files
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  5. #5
    Forum Moderator vlady's Avatar
    Join Date
    09-22-2011
    Location
    Philippines - OLSHCO -Guimba-Nueva Ecija
    MS-Off Ver
    2021
    Posts
    4,361

    Re: Semicolon delimited list

    another one.
    have to upload since i also worked I used right function from "Group1"

    semicolon.xlsx

  6. #6
    Registered User
    Join Date
    10-01-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    11

    Re: Semicolon delimited list

    Thanks for that Marvin and Vladimir, it is a huge step to solving my problem.

    I was wondering how to modify the formula to include more groups? Sorry if this seems basic, I appreciate the help. As you can see in the example, some of the numbers go up to 7 (which means the 7th group) ot (other) is always the last group when it is included - I have other variables which have between 5 and 17 groups, so it would be great if one of you could explain this to me so I can apply this to the different variables.

  7. #7
    Forum Moderator vlady's Avatar
    Join Date
    09-22-2011
    Location
    Philippines - OLSHCO -Guimba-Nueva Ecija
    MS-Off Ver
    2021
    Posts
    4,361

    Re: Semicolon delimited list

    just fill the header like in marvin's sample from 1,2,3,4,ot to 1,2,3,4,5,6,7,8,9,10 etc. (locatedin row 1),then use fill handle accross the sheet then down.
    you do not need to alter the formula just the header.

  8. #8
    Registered User
    Join Date
    10-01-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    11

    Re: Semicolon delimited list

    Excellent! Problem solved

    thanks very much

  9. #9
    Registered User
    Join Date
    10-01-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    11

    Re: Semicolon delimited list

    Hi again everyone,

    Just having another little issue with the formula:

    In some cases I have more than 10 groups. Unfortunately, if I there is a "12" in the lookup column, this is recognised as belonging to groups 1, 2, and 12. I have attached another example - I am not sure how to make the formula look up an exact match rather than just containing the numeral in the header.

    Thanks!
    Attached Files Attached Files

  10. #10
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: Semicolon delimited list

    Hi,

    You could change your formula in C3 to this array formula (important that you know how to enter this type of formula in Excel) and copy across and down:

    =IF(ISNUMBER(MATCH(C$1,--TRIM(MID(SUBSTITUTE($A3,";",REPT(" ",255)),255*(ROW(INDIRECT("1:"&1+LEN($A3)-LEN(SUBSTITUTE($A3,";",""))))-1)+1,255)),0)),C$1,"")

    Regards
    Click * below if this answer helped

    Advanced Excel Techniques: http://excelxor.com/

  11. #11
    Registered User
    Join Date
    10-01-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    11

    Re: Semicolon delimited list

    It would help if I did know how to enter the array formula - as a beginner I have no idea and my google searches have not been particularly enlightening except to tell me to press cnt +sht+enter

    If you could walk me through it that would be great

  12. #12
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: Semicolon delimited list

    Sure.

    Basically, when you've pasted the formula into the cell, go into the formula bar (as if to edit it) and, instead of pressing just ENTER as you would with a normal formula, first hold down CTRL and SHIFT and only then press ENTER.

    You'll notice curly brackets {} around the formula if you've done it correctly.

    Regards

  13. #13
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: Semicolon delimited list

    add the semi colon to both ends and remove any spaces
    =IFERROR(IF(FIND(";"&C$1&";",";"&SUBSTITUTE($A3," ","")&";")>0,C$1,""),"")
    Attached Files Attached Files
    Last edited by martindwilson; 10-07-2013 at 07:55 AM.
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  14. #14
    Registered User
    Join Date
    10-01-2013
    Location
    New Zealand
    MS-Off Ver
    Excel 2010
    Posts
    11

    Re: Semicolon delimited list

    Thank you both very much! These were fantastic solutions

  15. #15
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: Semicolon delimited list

    You're welcome.

+ 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. Semicolon delimited text files
    By gnoke in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 08-08-2013, 08:51 AM
  2. convert cvs to xls - Semicolon delimited
    By frhling in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 12-15-2012, 04:35 PM
  3. Open text file delimited semicolon with VBA
    By pezalmendra in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 09-20-2012, 11:23 AM
  4. [SOLVED] Saving Excel sheet as a semicolon delimited file (.csv)
    By e_dog95 in forum Excel General
    Replies: 1
    Last Post: 02-18-2006, 07:10 PM
  5. Replies: 1
    Last Post: 04-14-2005, 12:06 PM

Tags for this Thread

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