<?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: function unknown in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/function-unknown/m-p/293378#M61048</link>
    <description>&lt;P&gt;The function you are looking for is tranwrd():&lt;/P&gt;
&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/lrdict/64316/HTML/default/viewer.htm#a000215027.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/lrdict/64316/HTML/default/viewer.htm#a000215027.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;A search for string functions will yield you many different types of string processing functions.&lt;/P&gt;
&lt;P&gt;Example:&lt;/P&gt;
&lt;PRE&gt;data want;
  text="abc,def.";
  /* replace comma with 1 */
  new_text=tranwrd(text,",","1");
  /* replace dot with A */
  new_text=tranwrd(new_text,".","A");
run;&lt;/PRE&gt;</description>
    <pubDate>Tue, 23 Aug 2016 10:18:30 GMT</pubDate>
    <dc:creator>RW9</dc:creator>
    <dc:date>2016-08-23T10:18:30Z</dc:date>
    <item>
      <title>function unknown</title>
      <link>https://communities.sas.com/t5/SAS-Programming/function-unknown/m-p/293376#M61047</link>
      <description>&lt;P&gt;Hi everybody,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;is there a function for following problem:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I have a string like "abc,def." and I want replace "," and "."&amp;nbsp; with numbers or characters. I just want use the function once.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Cons.&lt;/P&gt;</description>
      <pubDate>Tue, 23 Aug 2016 10:10:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/function-unknown/m-p/293376#M61047</guid>
      <dc:creator>cons</dc:creator>
      <dc:date>2016-08-23T10:10:39Z</dc:date>
    </item>
    <item>
      <title>Re: function unknown</title>
      <link>https://communities.sas.com/t5/SAS-Programming/function-unknown/m-p/293378#M61048</link>
      <description>&lt;P&gt;The function you are looking for is tranwrd():&lt;/P&gt;
&lt;P&gt;&lt;A href="http://support.sas.com/documentation/cdl/en/lrdict/64316/HTML/default/viewer.htm#a000215027.htm" target="_blank"&gt;http://support.sas.com/documentation/cdl/en/lrdict/64316/HTML/default/viewer.htm#a000215027.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;A search for string functions will yield you many different types of string processing functions.&lt;/P&gt;
&lt;P&gt;Example:&lt;/P&gt;
&lt;PRE&gt;data want;
  text="abc,def.";
  /* replace comma with 1 */
  new_text=tranwrd(text,",","1");
  /* replace dot with A */
  new_text=tranwrd(new_text,".","A");
run;&lt;/PRE&gt;</description>
      <pubDate>Tue, 23 Aug 2016 10:18:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/function-unknown/m-p/293378#M61048</guid>
      <dc:creator>RW9</dc:creator>
      <dc:date>2016-08-23T10:18:30Z</dc:date>
    </item>
    <item>
      <title>Re: function unknown</title>
      <link>https://communities.sas.com/t5/SAS-Programming/function-unknown/m-p/293379#M61049</link>
      <description>&lt;P&gt;You cam do both replacement at same time by:&lt;/P&gt;&lt;P&gt;new_text = translate(old_text,'12',',.');&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;argument for translate are: input string, replace into chracters, repce from characters.&lt;/P&gt;&lt;P&gt;the order of chracters should fit;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Aug 2016 10:27:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/function-unknown/m-p/293379#M61049</guid>
      <dc:creator>Shmuel</dc:creator>
      <dc:date>2016-08-23T10:27:46Z</dc:date>
    </item>
    <item>
      <title>Re: function unknown</title>
      <link>https://communities.sas.com/t5/SAS-Programming/function-unknown/m-p/293393#M61051</link>
      <description>&lt;P&gt;You are correct translate is the preferred function to use when changing single characters.&lt;/P&gt;</description>
      <pubDate>Tue, 23 Aug 2016 11:47:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/function-unknown/m-p/293393#M61051</guid>
      <dc:creator>data_null__</dc:creator>
      <dc:date>2016-08-23T11:47:24Z</dc:date>
    </item>
  </channel>
</rss>

