Address list

sajohnson05

New Member
Joined
Aug 21, 2013
Messages
20
I have a list of over 1200 addresses. Some of them include the full address city state zip, some are missing the zip and some are just a street address. I am wanting to create 4 columns but i can not figure the best way to do this since the data that i am currently using is so different. Any help would be great.

7325 Medical Center Drive Suites 104 and 105 West Hills, CA 91307
2191 E. Johnson Ave. Pensacola, Fl.
12141 Richmond Avenue

Address City State Zip
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.
I assume there's no chance you can separate the address from the city with a comma?!?!

If your data is in column A, starting in row 2,
I believe I can get the zip codes using this:
Code:
=IF(ISNUMBER(1*RIGHT(A2,5)),RIGHT(A2,5),"")

I then think I can get the state using this:
Code:
=IF(EXACT(RIGHT(IF(ISNUMBER(1*RIGHT(A2,5)),LEFT(A2,LEN(A2)-6),RIGHT(A2,2)),2),UPPER(RIGHT(IF(ISNUMBER(1*RIGHT(A2,5)),LEFT(A2,LEN(A2)-6),RIGHT(A2,2)),2))),RIGHT(IF(ISNUMBER(1*RIGHT(A2,5)),LEFT(A2,LEN(A2)-6),RIGHT(A2,2)),2),"")

Phew!!
 
Upvote 0
If you could have a comma after the address and before the city, I think this will get the city:

Code:
=IFERROR(TRIM(MID(A2,FIND("^",SUBSTITUTE(A2,",","^",1))+1,FIND("^",SUBSTITUTE(A2,",","^",2))-FIND("^",SUBSTITUTE(A2,",","^",1))-1)),"")
 
Upvote 0
Again, if you can have the comma delimiter, this will give you the address:

Code:
=IF(1=FIND(C2,A2),A2,LEFT(A2,FIND(C2,A2)-3))

Using:

7325 Medical Center Drive Suites 104 and 105, West Hills, CA 91307
2191 E. Johnson Ave., Pensacola, FL
12141 Richmond Avenue
100 Main Street, San Diego, CA 92122

I cannot think of a way to insert the comma after the address and before the city. SIGH
 
Last edited:
Upvote 0
This has help a lot. I know going through all these lines wont be fun but sometimes you got to do the dirty work to clean data.
 
Upvote 0

Forum statistics

Threads
1,216,153
Messages
6,129,176
Members
449,491
Latest member
maxim_sivakon

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top