<?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 How to pull or delete information from a variable in SAS Data Science</title>
    <link>https://communities.sas.com/t5/SAS-Data-Science/How-to-pull-or-delete-information-from-a-variable/m-p/10821#M34</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I figured it out. &lt;/P&gt;&lt;P&gt;Went through some of my old code and decided to do the following:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; zipcode_short = substr(zip,1,5);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Did exactly what I was needing. &lt;/P&gt;&lt;P&gt;Decided to post the answer to my own question in case someone else had a similar one and could use the information. &lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 16 Sep 2011 14:51:11 GMT</pubDate>
    <dc:creator>HyunJee</dc:creator>
    <dc:date>2011-09-16T14:51:11Z</dc:date>
    <item>
      <title>How to pull or delete information from a variable</title>
      <link>https://communities.sas.com/t5/SAS-Data-Science/How-to-pull-or-delete-information-from-a-variable/m-p/10820#M33</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have two instances:&lt;/P&gt;&lt;P&gt;First, I have a data set that contains zip code. Most are the typical 5 digits, but I have some that contain the last four, like so:&lt;/P&gt;&lt;P&gt;731101014&amp;nbsp;&amp;nbsp; (contains the first 5 and last 4, not separated by anything) &lt;/P&gt;&lt;P&gt; 731101014 &lt;/P&gt;&lt;P&gt; 731101014 &lt;/P&gt;&lt;P&gt; 731101014 &lt;/P&gt;&lt;P&gt;73108&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; (contains only the first five *what I am needing all zip codes to be formatted in)&lt;/P&gt;&lt;P&gt; 73108 &lt;/P&gt;&lt;P&gt; 73108 &lt;/P&gt;&lt;P&gt; 73108&lt;/P&gt;&lt;P&gt; 73108&amp;nbsp; &lt;/P&gt;&lt;P&gt;73013-0000&amp;nbsp; (contains the first 5 and last 4, separated by a dash - ) &lt;/P&gt;&lt;P&gt; 73013-0000&lt;/P&gt;&lt;P&gt; 73013-0000 &lt;/P&gt;&lt;P&gt; 73013-0000 &lt;/P&gt;&lt;P&gt; 73013-0000&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am on a bit of a time crunch and need any help I can get on how to best write code to only pull out the first 5 numbers from each zip code and ditch the rest.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for any help you can give!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 Sep 2011 14:41:44 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Science/How-to-pull-or-delete-information-from-a-variable/m-p/10820#M33</guid>
      <dc:creator>HyunJee</dc:creator>
      <dc:date>2011-09-16T14:41:44Z</dc:date>
    </item>
    <item>
      <title>How to pull or delete information from a variable</title>
      <link>https://communities.sas.com/t5/SAS-Data-Science/How-to-pull-or-delete-information-from-a-variable/m-p/10821#M34</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I figured it out. &lt;/P&gt;&lt;P&gt;Went through some of my old code and decided to do the following:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; zipcode_short = substr(zip,1,5);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Did exactly what I was needing. &lt;/P&gt;&lt;P&gt;Decided to post the answer to my own question in case someone else had a similar one and could use the information. &lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 16 Sep 2011 14:51:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Data-Science/How-to-pull-or-delete-information-from-a-variable/m-p/10821#M34</guid>
      <dc:creator>HyunJee</dc:creator>
      <dc:date>2011-09-16T14:51:11Z</dc:date>
    </item>
  </channel>
</rss>

