Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Hello-
Our database sends our adress info without specific delimters - ie City_State_Zip (I know this should mean that it is delimted by a space but we have several cities with a space in the name :) Is there a way to split based on the text contained - ie everything before the first two cap COmbination or Enter a specific state abrieviation etc? |
#2
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
On Fri, 12 Oct 2007 12:54:01 -0700, betany70
wrote: Hello- Our database sends our adress info without specific delimters - ie City_State_Zip (I know this should mean that it is delimted by a space but we have several cities with a space in the name :) Is there a way to split based on the text contained - ie everything before the first two cap COmbination or Enter a specific state abrieviation etc? If the STATE is always a two letter abbreviation bounded by <spaces, and the Zip is at the end with no included spaces, then you could use the following formulas: City: All words up to next-to-last <space =LEFT(A1,FIND(CHAR(1),SUBSTITUTE(A1," ",CHAR(1), LEN(A1)-LEN(SUBSTITUTE(A1," ",""))-1))-1) State: The two characters following next-to-last <space =MID(A1,1+FIND(CHAR(1),SUBSTITUTE(A1," ",CHAR(1), LEN(A1)-LEN(SUBSTITUTE(A1," ",""))-1)),2) Zip: All the characters after the last <space =MID(A1,FIND(CHAR(1),SUBSTITUTE(A1," ",CHAR(1), LEN(A1)-LEN(SUBSTITUTE(A1," ",""))))+1,255) --ron |
#3
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Beautiful - thanks!
"Ron Rosenfeld" wrote: On Fri, 12 Oct 2007 12:54:01 -0700, betany70 wrote: Hello- Our database sends our adress info without specific delimters - ie City_State_Zip (I know this should mean that it is delimted by a space but we have several cities with a space in the name :) Is there a way to split based on the text contained - ie everything before the first two cap COmbination or Enter a specific state abrieviation etc? If the STATE is always a two letter abbreviation bounded by <spaces, and the Zip is at the end with no included spaces, then you could use the following formulas: City: All words up to next-to-last <space =LEFT(A1,FIND(CHAR(1),SUBSTITUTE(A1," ",CHAR(1), LEN(A1)-LEN(SUBSTITUTE(A1," ",""))-1))-1) State: The two characters following next-to-last <space =MID(A1,1+FIND(CHAR(1),SUBSTITUTE(A1," ",CHAR(1), LEN(A1)-LEN(SUBSTITUTE(A1," ",""))-1)),2) Zip: All the characters after the last <space =MID(A1,FIND(CHAR(1),SUBSTITUTE(A1," ",CHAR(1), LEN(A1)-LEN(SUBSTITUTE(A1," ",""))))+1,255) --ron |
#4
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
Have your "database" send you the information, in a format acceptable to
Excel (or any other software). i.e. City, delimiter, State delimiter, etc Almost all software is capable of creating delimited files. Tyro "betany70" wrote in message ... Hello- Our database sends our adress info without specific delimters - ie City_State_Zip (I know this should mean that it is delimted by a space but we have several cities with a space in the name :) Is there a way to split based on the text contained - ie everything before the first two cap COmbination or Enter a specific state abrieviation etc? |
#5
![]()
Posted to microsoft.public.excel.misc
|
|||
|
|||
![]()
On Fri, 12 Oct 2007 13:42:04 -0700, betany70
wrote: Beautiful - thanks! You're welcome. Thanks for the feedback. --ron |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Splitting Numeric data from Text (Street Address Help) | Excel Discussion (Misc queries) | |||
Splitting text, like "Text to columns", but as a formula | Excel Discussion (Misc queries) | |||
Splitting text to columns | Excel Worksheet Functions | |||
Splitting text in one column into two (or more) columns. | Excel Worksheet Functions | |||
splitting text to multiple columns | Excel Discussion (Misc queries) |