+ Reply to Thread
Results 1 to 6 of 6

extract an address from multple words and a number in a cell

  1. #1
    Registered User
    Join Date
    10-04-2013
    Location
    hogwarts
    MS-Off Ver
    Excel 2010
    Posts
    9

    extract an address from multple words and a number in a cell

    Hello,

    In cell A1=990988 barker bed golf and beyond #456545 2434 main st 98745.
    (contains the ID number, business name, and address)


    i want cell b1 to show (the address) 2434 main st 98745

    I want cell c1 to show all the other information besides the address and the ID number before the business name.
    (just the business name)


    how do I make permanant formula or process, like multiple formulas to temporary trim the data for this without VBA.

    Please keep in mind, the ID number is always the same amount of digits, but the business name may have different words and different spaces, and may not have a number after the business name.

    Thanks.
    Last edited by excelZen; 01-30-2015 at 03:37 PM.

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

    Re: extract an address from multple words and a number in a cell

    Hi excelZen,

    Can you use the "#" sign to deal with splitting up this string? See the attached.
    Attached Files Attached Files
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  3. #3
    Registered User
    Join Date
    10-04-2013
    Location
    hogwarts
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: extract an address from multple words and a number in a cell

    Hi Marvin,
    Thanks for your reply.
    Your solution of =MID(A1,FIND("#",A1)+8,100)

    works, for the example above, but what happens when there is no # sign.


    Also i wanted C1 to "show barker bed golf and beyond #456545"

    and not the numbers in front of barker bed golf and beyohd.

    is there a way to use the left, mid or right, to count the number of spaces in the cell and then use a formula.
    Not all entries have a # sign , but do have multiple spaces, but not all the number of spaces are the same.
    Last edited by excelZen; 01-29-2015 at 07:23 PM.

  4. #4
    Registered User
    Join Date
    10-04-2013
    Location
    hogwarts
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: extract an address from multple words and a number in a cell

    EDIT: i was thinking if I removed the zipcode with a right command, all we would have left is the address, which would be :

    number value, text text text. 2020 Johnson court

    would there be a formula for excel to find the 1st numerical value and the end of the cell, and return the numerical value and all the text after it.

  5. #5
    Registered User
    Join Date
    05-10-2013
    Location
    Pomáz, Hungary
    MS-Off Ver
    Excel 2007
    Posts
    78

    Re: extract an address from multple words and a number in a cell

    If the data is in col A, enter this in B1 with Ctrl + Shift + Enter:

    =RIGHT(A1,MATCH(1,1*(MID(A1,LEN(A1)-ROW(INDIRECT("1:"&LEN(A1)))-9,1)=" ")*ISNUMBER(1*MID(A1,LEN(A1)-ROW(INDIRECT("1:"&LEN(A1)))-8,1)),0)+9)


    Enter this formula in C1 (just with Enter):

    =MID(SUBSTITUTE(A1," "&B1,""),8,100)

  6. #6
    Registered User
    Join Date
    10-04-2013
    Location
    hogwarts
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: extract an address from multple words and a number in a cell

    Thanks, Istvan Hirsch and Marvin P and everyone that viewed this topic and tried to help.

    Marvin thanks for your formula the 1st part worked and 2nd did too.
    But the 2nd formula doesn't work for all my entries. Some entries have different amount of spaces and words.

    I used a difference of lens from the result from cell B1 and A1 and used a left command.

    THanks ALL! I will mark this as solved.

+ 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] Find an highlight multple words in different colors
    By Niclal in forum Excel Programming / VBA / Macros
    Replies: 35
    Last Post: 04-07-2014, 09:37 AM
  2. Insert Number of Rows based on value within a cell... multple times
    By nyiballs in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 12-18-2013, 10:46 AM
  3. [SOLVED] Extract data[number] from a set of [words,number and symbol] and place into column
    By dragon_m0nsta in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 08-12-2012, 08:31 PM
  4. Extract House Number from Street Address into new Cell
    By tamorgen in forum Excel Programming / VBA / Macros
    Replies: 14
    Last Post: 10-20-2011, 07:48 AM
  5. extract street number from address
    By rickshadey in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 10-23-2008, 08:51 PM

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