<?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: susbtr a string of characters in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/susbtr-a-string-of-characters/m-p/330094#M73977</link>
    <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;length twoWords $16;
twoWords = catx(" ", scan(food, 1), scan(food, 2));&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Mon, 06 Feb 2017 04:17:17 GMT</pubDate>
    <dc:creator>PGStats</dc:creator>
    <dc:date>2017-02-06T04:17:17Z</dc:date>
    <item>
      <title>susbtr a string of characters</title>
      <link>https://communities.sas.com/t5/SAS-Programming/susbtr-a-string-of-characters/m-p/330092#M73975</link>
      <description>&lt;P&gt;HI,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; AS I am confronted with a problem about'substr', now i just want to get the first two characters from the string of characters.&lt;/P&gt;&lt;P&gt;like : apple juice is my favorite food. i need the 'apple juice'.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;i have tried to parse the string and get the var1 for 'apple', var2 for 'juice' and coding like this ' m1 = substr(food,1,compress(var1!!var2)), however, the result is all characters in the string which is not i wanted.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;i am wondering the better solution to it and the reasons why 'compress' not work out.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you!&lt;/P&gt;</description>
      <pubDate>Mon, 06 Feb 2017 04:06:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/susbtr-a-string-of-characters/m-p/330092#M73975</guid>
      <dc:creator>JNWong</dc:creator>
      <dc:date>2017-02-06T04:06:36Z</dc:date>
    </item>
    <item>
      <title>Re: susbtr a string of characters</title>
      <link>https://communities.sas.com/t5/SAS-Programming/susbtr-a-string-of-characters/m-p/330094#M73977</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;length twoWords $16;
twoWords = catx(" ", scan(food, 1), scan(food, 2));&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 06 Feb 2017 04:17:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/susbtr-a-string-of-characters/m-p/330094#M73977</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2017-02-06T04:17:17Z</dc:date>
    </item>
  </channel>
</rss>

