<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Splitting Address in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740224#M231177</link>
    <description>&lt;P&gt;Iowa is always spelled out in full (including other states)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There are no 9 digit zip. All are 5 digits&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There are only blank separators between address and city name and between most of the elements. The only comma separator is after the state name. Column (:) separators are after the text " Address" and after the text "Phone Number"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;</description>
    <pubDate>Mon, 10 May 2021 16:19:18 GMT</pubDate>
    <dc:creator>malangba</dc:creator>
    <dc:date>2021-05-10T16:19:18Z</dc:date>
    <item>
      <title>Splitting Address</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740179#M231151</link>
      <description>&lt;P&gt;I have an address column in my dataset that I wanted to parse to put city and zip code in their separate columns. Positions differ in many of the addresses. Examples of address types in the data are:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. Address: 321 E 12th St Des Moines Iowa, 50321phone Number: (515) 515-5151&lt;/P&gt;&lt;P&gt;2. Address: 321 Iowa st Boone Iowa, 50321Phone Number:&amp;nbsp;(515) 515-5151&lt;/P&gt;&lt;P&gt;3. Address:&amp;nbsp;321 Des Moines st Suite 140 Iowa City Iowa, 50321Phone Number:&amp;nbsp;(515) 515-5151&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 10 May 2021 13:32:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740179#M231151</guid>
      <dc:creator>malangba</dc:creator>
      <dc:date>2021-05-10T13:32:15Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting Address</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740180#M231152</link>
      <description>&lt;P&gt;It's nearly impossible for us to create a set of rules based on your three examples that will likely work on a wide variety of real-life examples.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could you state the rules to find city and Zip Code that you think will work given the real data that you have?&lt;/P&gt;</description>
      <pubDate>Mon, 10 May 2021 13:48:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740180#M231152</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-05-10T13:48:47Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting Address</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740184#M231155</link>
      <description>&lt;P&gt;I do not really have any rules in mind. And these examples are real data.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 10 May 2021 14:16:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740184#M231155</guid>
      <dc:creator>malangba</dc:creator>
      <dc:date>2021-05-10T14:16:54Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting Address</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740188#M231157</link>
      <description>&lt;P&gt;Yes, but you can come up with rules by looking at the real data (which we can't do) and then tell us what those rules are that you think will work, and then we can help you program them.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 10 May 2021 14:23:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740188#M231157</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-05-10T14:23:29Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting Address</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740192#M231159</link>
      <description>&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/19356"&gt;@malangba&lt;/a&gt;&amp;nbsp;&lt;BR /&gt;Parsing addresses is difficult, there's a good reply in a thread on Stack Overflow:&lt;BR /&gt;&lt;A href="https://stackoverflow.com/questions/11160192/how-to-parse-freeform-street-postal-address-out-of-text-and-into-components" target="_blank"&gt;https://stackoverflow.com/questions/11160192/how-to-parse-freeform-street-postal-address-out-of-text-and-into-components&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;At the end of the day, you will need to come up with some rules for your situation/data.&lt;BR /&gt;&lt;BR /&gt;As&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/10892"&gt;@PaigeMiller&lt;/a&gt;&amp;nbsp;states, you need to review your data and come up with rules that work for your data.&lt;BR /&gt;&lt;BR /&gt;Looking at your 3 sample lines, you can strip out the phone number, and probably get the zip, as long as nobody has long zip format (50321-1234). Getting the state/city that's going to be problematic as per the thread linked above.&lt;/P&gt;</description>
      <pubDate>Mon, 10 May 2021 14:30:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740192#M231159</guid>
      <dc:creator>AMSAS</dc:creator>
      <dc:date>2021-05-10T14:30:10Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting Address</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740195#M231161</link>
      <description>&lt;P&gt;So all I really needed from this address column is the City name and Zip code.&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. The city name can be one or two words, followed by State name and then a comma ","&lt;/P&gt;&lt;P&gt;2. Zip codes are only 5 numbers&lt;/P&gt;&lt;P&gt;3. Some address are missing everything except the state name&lt;/P&gt;&lt;P&gt;4. There are addresses from other states, but only interested in those that has Iowa as the state&lt;/P&gt;</description>
      <pubDate>Mon, 10 May 2021 14:44:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740195#M231161</guid>
      <dc:creator>malangba</dc:creator>
      <dc:date>2021-05-10T14:44:54Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting Address</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740197#M231163</link>
      <description>&lt;P&gt;Also, If zip codes is not blank, it is right after a comma&lt;/P&gt;</description>
      <pubDate>Mon, 10 May 2021 14:48:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740197#M231163</guid>
      <dc:creator>malangba</dc:creator>
      <dc:date>2021-05-10T14:48:09Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting Address</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740203#M231168</link>
      <description>&lt;P&gt;Sorry. City can actually be up to 3 words.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 10 May 2021 14:55:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740203#M231168</guid>
      <dc:creator>malangba</dc:creator>
      <dc:date>2021-05-10T14:55:55Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting Address</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740216#M231173</link>
      <description>&lt;P&gt;Is Iowa always spelled out, all four letters, or is it sometimes abbreviated as IA?&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Are there every 9 digit zip codes?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Are there separators between address and city name other than a blank?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Again, there are lots of possibilities and you have addressed a few, but I'm sure there are many complications that you haven't addressed yet.&lt;/P&gt;</description>
      <pubDate>Mon, 10 May 2021 15:51:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740216#M231173</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-05-10T15:51:33Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting Address</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740224#M231177</link>
      <description>&lt;P&gt;Iowa is always spelled out in full (including other states)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There are no 9 digit zip. All are 5 digits&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;There are only blank separators between address and city name and between most of the elements. The only comma separator is after the state name. Column (:) separators are after the text " Address" and after the text "Phone Number"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you&lt;/P&gt;</description>
      <pubDate>Mon, 10 May 2021 16:19:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740224#M231177</guid>
      <dc:creator>malangba</dc:creator>
      <dc:date>2021-05-10T16:19:18Z</dc:date>
    </item>
    <item>
      <title>Re: Splitting Address</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740227#M231180</link>
      <description>&lt;P&gt;I hope you get some idea of how difficult this is in general (and I hope you read the link from&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/226241"&gt;@AMSAS&lt;/a&gt;&amp;nbsp;)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In your first record, there seems to be no way to decide if the city name is "Moines" or "Des Moines" or "St Des Moines".&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Some people use a list of place names to help them decide, especially if you have a zip code. That isn't specifically pulling apart the text string, as extra information is used. I don't have skills with such a procedure, but I'm sure someone here does.&lt;/P&gt;</description>
      <pubDate>Mon, 10 May 2021 17:01:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Splitting-Address/m-p/740227#M231180</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-05-10T17:01:37Z</dc:date>
    </item>
  </channel>
</rss>

