+ Reply to Thread
Results 1 to 4 of 4

alphanumeric sorting

  1. #1
    dancefle
    Guest

    alphanumeric sorting

    How do I change a column containing c1 c10 c11 c2 c21 c3 to sort as c1 c2 c3
    c10 c11 c21?

  2. #2
    L. Howard Kittle
    Guest

    Re: alphanumeric sorting

    One way, in a helper column next to your data enter and pull down.

    =RIGHT(A1,LEN(A1)-1)*1

    Select both columns and sort by the helper column. Delete helper column.

    HTH
    Regards,
    Howard

    "dancefle" <dancefle@discussions.microsoft.com> wrote in message
    news:E2102EDC-3B7E-4B70-B611-20320F104BEB@microsoft.com...
    > How do I change a column containing c1 c10 c11 c2 c21 c3 to sort as c1 c2
    > c3
    > c10 c11 c21?




  3. #3
    Ragdyer
    Guest

    Re: alphanumeric sorting

    One way is to use TTC (Text To Columns).

    Select the data in the column, then <Data> <TTC>,
    Click "Fixed Width", then <Next>,
    Click in the window, and drag the break line to separate the "C" from the
    numbers, then <Next>.

    The column containing the "C" should be selected (black), so click on "Do
    Not Import (skip)".

    Then click in the "Destination" window, and enter the address of the column
    next to your original.
    What this does is preserve your data in it's original location, without
    changing anything, and moves *only* the numbers to the next column, skipping
    (leaving behind) the letters.
    Now, click <Finish>.

    You should now have your original column of data, and an adjoining column of
    numbers, where you now select *both* columns, and sort on the number column
    to get your text column of data sorted numerically.

    You can then delete the "helper' column of numbers.
    --
    HTH,

    RD

    ---------------------------------------------------------------------------
    Please keep all correspondence within the NewsGroup, so all may benefit !
    ---------------------------------------------------------------------------
    "dancefle" <dancefle@discussions.microsoft.com> wrote in message
    news:E2102EDC-3B7E-4B70-B611-20320F104BEB@microsoft.com...
    > How do I change a column containing c1 c10 c11 c2 c21 c3 to sort as c1 c2

    c3
    > c10 c11 c21?



  4. #4
    David McRitchie
    Guest

    Re: alphanumeric sorting

    If you actual data is a bit more complicated you might want to take a
    look at
    Sorting product code with alpha prefix and numeric suffix (#pcdigits)
    http://www.mvps.org/dmcritchie/excel...g.htm#pcdigits
    ---
    HTH,
    David McRitchie, Microsoft MVP - Excel [site changed Nov. 2001]
    My Excel Pages: http://www.mvps.org/dmcritchie/excel/excel.htm
    Search Page: http://www.mvps.org/dmcritchie/excel/search.htm

    "dancefle" <dancefle@discussions.microsoft.com> wrote in message news:E2102EDC-3B7E-4B70-B611-20320F104BEB@microsoft.com...
    > How do I change a column containing c1 c10 c11 c2 c21 c3 to sort as c1 c2 c3
    > c10 c11 c21?




+ 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