+ Reply to Thread
Results 1 to 14 of 14

Sorting cell that contains TEXT only

  1. #1
    Registered User
    Join Date
    12-13-2012
    Location
    Office
    MS-Off Ver
    Excel 2007
    Posts
    7

    Red face Sorting cell that contains TEXT only

    Hi All,

    I'm a newbie in this forum I need help with my project in which I have to deal with various type of data.

    So, I have big data in excel that require me to sort out the cell that contain "TEXT" only value. Below I enlist some dummy data which pretty similar with the one I have to deal with.


    A | B |
    0303-numbers
    0303numbers
    0313so
    031v13807x
    0330-numbers
    0333-numbers
    BOOKISGOOD
    careers-seminar
    newyork
    holland-newyork
    123456



    From the above data, I need to get the cell that contain TEXT only (no dashes, no numbers) which are: "BOOKISGOOD" and "NEWYORK". So maybe for this cell I want a remark "X" in column B.

    As for the cell that contain "dashes"/ (-) with "Y" remark in column B, and NUMBERS only cell with "Z" remark, and cell with combination of TEXTS and NUMBERS with "O" remark.

    I really appreciate if anyone could help me to share some insights how to accomplish this project.

    Thanks in advance

  2. #2
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Sorting cell that contains TEXT only

    what about numbers and text with a "-" in them?
    (ie:0303-numbers)
    A picture may be worth a thousand words, BUT, a sample Workbook is worth a thousand screenshots!
    -Add a File - click advanced (next to quick post), scroll to manage attachments, click, select add files, click select files, select file, click upload, when file shows up at bottom left, click done (bottom right), click submit
    -To mark thread Solved- go top of thread,click Thread Tools,click Mark as Solved
    If you received helpful response, please remember to hit the * of that post

  3. #3
    Forum Guru :) Sixthsense :)'s Avatar
    Join Date
    01-01-2012
    Location
    India>Tamilnadu>Chennai
    MS-Off Ver
    2003 To 2010
    Posts
    12,770

    Re: Sorting cell that contains TEXT only

    In B1 cell
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    If your problem is solved, then please mark the thread as SOLVED>>Above your first post>>Thread Tools>>
    Mark your thread as Solved


    If the suggestion helps you, then Click *below to Add Reputation

  4. #4
    Registered User
    Join Date
    12-13-2012
    Location
    Office
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Sorting cell that contains TEXT only

    It should get "Y" remark since it has dash in them
    Quote Originally Posted by dredwolf View Post
    what about numbers and text with a "-" in them?
    (ie:0303-numbers)

  5. #5
    Registered User
    Join Date
    12-13-2012
    Location
    Office
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Sorting cell that contains TEXT only

    Quote Originally Posted by :) Sixthsense :) View Post
    In B1 cell
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Hi Sixthsense,

    I really appreciate your quick help and response Never joined any forums before that response to the help inquiry so fast and responsive like this forum.

    However, I think although it's "close enough" but I think it's still required some adjustments

    Below is the result after trying your formula:

    name | Sixthsense's | Should be
    -----------------------------------------------------
    0303-numbers | O | Y
    0303numbers | X | O
    0313so | X | O
    031v13807x | X | O
    0330-numbers | O | Y
    0333-numbers | O | Y
    BOOKISGOOD | X | X
    careers-seminar | Y | Y
    newyork | X | X
    holland-newyork | Y | Y
    123456 | X | Z

    I'm really sorry if it seems very complicated. And at the moment the most important thing that I need to sort out from this data is how I can get the "X" remark correctly (the cell with ALPHABETS/TEXT only and no NUMBER or DASH at all).

    So, based on the dummy data there should be only 2 "X" The other remarks are just my precautionary, just in case those data will be required in the future too.

    Many thanks in advance for the helps.

  6. #6
    Forum Guru :) Sixthsense :)'s Avatar
    Join Date
    01-01-2012
    Location
    India>Tamilnadu>Chennai
    MS-Off Ver
    2003 To 2010
    Posts
    12,770

    Re: Sorting cell that contains TEXT only

    Thanks for the feedback

    One request from my end please attach your sample data with expected output which will be very much helpful for our workings and better understanding of your data structure.

  7. #7
    Registered User
    Join Date
    12-13-2012
    Location
    Office
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Sorting cell that contains TEXT only

    Quote Originally Posted by :) Sixthsense :) View Post
    Thanks for the feedback

    One request from my end please attach your sample data with expected output which will be very much helpful for our workings and better understanding of your data structure.
    Uhm, can you tell me how to attach file? I can't find the option to attach file. However, as the alternative i attached screenshot of the excel instead. Hope it could help you to get better picture of the expected result.

    Excel_forum.PNG

    Many thanks in advance ;-)

  8. #8
    Forum Guru :) Sixthsense :)'s Avatar
    Join Date
    01-01-2012
    Location
    India>Tamilnadu>Chennai
    MS-Off Ver
    2003 To 2010
    Posts
    12,770

    Re: Sorting cell that contains TEXT only

    I don't know then how you attached the screenshot, anyhow please go through the below method for attaching a file

    To Attach a File:

    1. Click on Go Advanced
    2. In the frame Attach Files you will see the button Manage Attachments
    3. Click the button.
    4. A new window will open titled Manage Attachments - Excel Forum.
    5. Click the Browse... button to locate your file for uploading.
    6. This will open a new window File Upload.
    7. Once you have located the file to upload click the Open button. This window will close.
    8. You are now back in the Manage Attachments - Excel Forum window.
    9. Click the Upload button and wait until the file has uploaded.
    10. Close the window and then click Submit.

  9. #9
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Sorting cell that contains TEXT only

    An alternative (with UDF) :
    first <Alt><F11>, Insert-> Module
    copy/paste this into the module:
    Please Login or Register  to view this content.
    Then use this formula, In B1 :
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Drag down

    Hope this helps

    Edit-
    You can change the NA() for "" if you don't like error messages, I went with that so you would know there was some unforeseen condition in your data..
    Last edited by dredwolf; 12-13-2012 at 03:57 AM.

  10. #10
    Valued Forum Contributor
    Join Date
    11-15-2008
    Location
    ph
    MS-Off Ver
    2007/2010/2016
    Posts
    479

    Re: Sorting cell that contains TEXT only

    Hi -

    I borrowed zbor formula and amend to suit for your needs.
    Please Login or Register  to view this content.
    Regards,
    Event

  11. #11
    Registered User
    Join Date
    12-13-2012
    Location
    Office
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Sorting cell that contains TEXT only

    Thanks guysssssssss It's solved now though I'll need to spend sometime later to learn about the formula. I am not familiar with the functions used above. I think I really have to learn a lot from you guys

    Thanks once again

  12. #12
    Forum Expert dredwolf's Avatar
    Join Date
    10-27-2012
    Location
    Clearwater,Canada
    MS-Off Ver
    Excel 2007
    Posts
    2,649

    Re: Sorting cell that contains TEXT only

    You are welcome !

  13. #13
    Valued Forum Contributor
    Join Date
    10-29-2012
    Location
    Mojokerto,Indonesia
    MS-Off Ver
    Excel 2007
    Posts
    554

    Re: Sorting cell that contains TEXT only

    try it (array formula)
    =INDEX(({"X";"O";"Z";"Y"});MATCH(COUNT(IFERROR(MID(SUBSTITUTE(A1;"-";REPT(0;LEN(A1)+1));ROW($1:$100);1)/1;""))/LEN(A1);({0;0,0001;1;1,0001})))
    Attached Files Attached Files

  14. #14
    Registered User
    Join Date
    12-13-2012
    Location
    Office
    MS-Off Ver
    Excel 2007
    Posts
    7

    Re: Sorting cell that contains TEXT only

    Quote Originally Posted by Ghozi Alkatiri View Post
    try it (array formula)
    =INDEX(({"X";"O";"Z";"Y"});MATCH(COUNT(IFERROR(MID(SUBSTITUTE(A1;"-";REPT(0;LEN(A1)+1));ROW($1:$100);1)/1;""))/LEN(A1);({0;0,0001;1;1,0001})))
    Although, it's been solved. Thanks also to Ghozi

+ 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