+ Reply to Thread
Results 1 to 6 of 6

Sorting columns by letter if they start with number first

  1. #1
    Registered User
    Join Date
    07-22-2008
    Location
    WV
    Posts
    70

    Sorting columns by letter if they start with number first

    I have a column with addresses (see attached image). When I sort it does so by number. I want to sort by street name then by number. Only problem is they are all in same column.

    Would it be best to use formula to separate the number then street name? If so, how? Or is there simpler way to do advanced sort or filter?

    Thanks

    sort.png

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,723

    Re: Sorting columns by letter if they start with number first

    Many contributors are not able to view .png files on this forum, due to software incompatibilities with some browsers. Attach a sample Excel workbook instead (the FAQ describes how to).

    Hope this helps.

    Pete

  3. #3
    Registered User
    Join Date
    07-22-2008
    Location
    WV
    Posts
    70

    Re: Sorting columns by letter if they start with number first

    Quote Originally Posted by Pete_UK View Post
    Many contributors are not able to view .png files on this forum, due to software incompatibilities with some browsers. Attach a sample Excel workbook instead (the FAQ describes how to).

    Hope this helps.

    Pete
    Basically I have this:

    10503 POTOMAC HIGHLANDS TRL
    1068 BUFFALO MOUNTAIN RD
    10753 POTOMAC HIGHLANDS TRL
    1087 BUFFALO MOUNTAIN RD
    109 DUNCAN RUN RD

    I want this:

    1068 BUFFALO MOUNTAIN RD
    1087 BUFFALO MOUNTAIN RD
    109 DUNCAN RUN RD
    10503 POTOMAC HIGHLANDS TRL
    10753 POTOMAC HIGHLANDS TRL

    Bold is just to emphasize how it is sorted. I have sorted by number. I want sorted by letter THEN by number.

    All data is in one column though. Is there advanced filter to sort by NAME first then by NUMBER when the cell starts with a number?

    If not, how could I use formula to separate the number into a separate column then sort?
    Last edited by jambog; 03-21-2016 at 11:48 AM.

  4. #4
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,723

    Re: Sorting columns by letter if they start with number first

    If your data starts in A1, you can put this formula in B1:

    =RIGHT(A1,LEN(A1)-FIND(" ",A1))

    and copy down to get the street name. You can also put this formula in C1:

    =--LEFT(A1,FIND(" ",A1)-1)

    to get the number, and copy that down. Then highlight the data in columns A to C and click on Data | Sort and use column B as the main sort field followed by column C. After sorting, you can delete columns B and C if you no longer need them.

    Hope this helps.

    Pete

  5. #5
    Registered User
    Join Date
    07-22-2008
    Location
    WV
    Posts
    70

    Re: Sorting columns by letter if they start with number first

    This works great, thank you!

  6. #6
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,723

    Re: Sorting columns by letter if they start with number first

    Glad to be able to help - thanks for the rep, and for marking the thread as SOLVED.

    Pete

+ 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] Sorting into multiple columns if 3rd digit is letter or number
    By GhostMerc in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 02-05-2015, 03:49 PM
  2. Refer to columns by number instead of letter
    By GerPis in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 05-23-2012, 11:29 AM
  3. Replies: 6
    Last Post: 03-21-2012, 06:27 AM
  4. Formula to Convert Letter to Number and then Average Columns
    By skwiskwis in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-07-2010, 03:39 PM
  5. Sorting number/letter combos
    By DADSCOOL2 in forum Excel General
    Replies: 2
    Last Post: 03-13-2009, 12:48 AM
  6. Format:change headers from letter to number/number to letter
    By Biff in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-06-2005, 04:05 AM
  7. worksheet columns changed from letter to number, how change back
    By Ron in forum Excel - New Users/Basics
    Replies: 2
    Last Post: 05-09-2005, 04: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