Forum Discussion

Diane307's avatar
Diane307
Copper Contributor
May 24, 2019

Separating an address in one column to columns: address1, address2, city, state

I need to separate a column listing addresses into 4 columns, address1, address2, city, state. Text to column does not separate because there is not any comma's only spaces and I cannot separate by spaces because there are required spaces in each part of the address

2 Replies

  • Rich99's avatar
    Rich99
    Iron Contributor

    Hi Diane307 Not sure of this will help, I have assumed that some parts of your addresses start with capital letters, the attached file shows how to identify each capitol letter in the address, get its location in the string then extract the remaining lower case letters. of course if you don't have any capitols then life becomes very difficult, if not impossible.

     

    Rich 

  • Twifoo's avatar
    Twifoo
    Silver Contributor
    There must be some delimiter for each part of the address; otherwise, no logic would explain how the address would be separated into parts.

Resources