Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Extracting House Numbers from Street Addresses

How do I extract house numbers from street addresses when the number of
characters varies.

For example, one address might be "4 Olde Coach Road," another might be "22
Olde Coach Road" or even "138 Cyber Lane" or even "1452 Digital Drive." At
times, there is even the odd "15 L Byte Boulevard."

Ultimately, I need to sort my list by street name, and to do so, I need to
extract the various leading numbers.

Thanks for your help.

--
George M.
gmfbard AT verizon DOT net


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Extracting House Numbers from Street Addresses

All your examples have a number followed by a blank followed by the rest of
the address:

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

--
Gary''s Student - gsnu200812
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Extracting House Numbers from Street Addresses

Thank you for your suggestion. This does and excellent job of displaying the
house number.

What I'd really like to do, though, is wind up with the street name, so that
I can sort on that value.

George M.

"Gary''s Student" wrote in message
...
All your examples have a number followed by a blank followed by the rest
of
the address:

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

--
Gary''s Student - gsnu200812



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Extracting House Numbers from Street Addresses

Hi George:

Quite easy. Our first formula looked for the first blank and display the
housenumber to the LEFT of the blank. This formula displays "the rest of the
story":

=MID(A1,FIND(" ",A1)+1,9999)


Thus if A1 contains 123 North Maple Avenue
then
=LEFT(A1,FIND(" ",A1)-1) will display 123
=MID(A1,FIND(" ",A1)+1,9999) will display North Maple Avenue


then
--
Gary''s Student - gsnu200812


"George M. Fodor" wrote:

Thank you for your suggestion. This does and excellent job of displaying the
house number.

What I'd really like to do, though, is wind up with the street name, so that
I can sort on that value.

George M.

"Gary''s Student" wrote in message
...
All your examples have a number followed by a blank followed by the rest
of
the address:

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

--
Gary''s Student - gsnu200812




  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Extracting House Numbers from Street Addresses

Excellent!

Thank you so much for your help.

George M.

--
"Gary''s Student" wrote in message
...
Hi George:

Quite easy. Our first formula looked for the first blank and display the
housenumber to the LEFT of the blank. This formula displays "the rest of
the
story":

=MID(A1,FIND(" ",A1)+1,9999)


Thus if A1 contains 123 North Maple Avenue
then
=LEFT(A1,FIND(" ",A1)-1) will display 123
=MID(A1,FIND(" ",A1)+1,9999) will display North Maple Avenue


then
--
Gary''s Student - gsnu200812


"George M. Fodor" wrote:

Thank you for your suggestion. This does and excellent job of displaying
the
house number.

What I'd really like to do, though, is wind up with the street name, so
that
I can sort on that value.

George M.

"Gary''s Student" wrote in
message
...
All your examples have a number followed by a blank followed by the
rest
of
the address:

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

--
Gary''s Student - gsnu200812






Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to House, 123 Street, Somewhere, M1 23X Nick C Excel Discussion (Misc queries) 1 July 23rd 08 03:31 PM
how do I look for duplicate house addresses in a column in Excel? Kevin S Excel Worksheet Functions 3 June 19th 07 09:15 PM
TRYING TO ALPHBETIZE STREET ADDRESSES Anna Excel Discussion (Misc queries) 1 October 26th 06 03:36 AM
Help! How to sort addresses by street then by #...... HelpingOthersTD New Users to Excel 1 June 15th 06 09:29 AM
Removing house numbers from addresses dalymjl Excel Worksheet Functions 3 April 24th 05 08:00 AM


All times are GMT +1. The time now is 09:05 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"