<?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: Help needed in understanding %str function in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Help-needed-in-understanding-str-function/m-p/749200#M235378</link>
    <description>&lt;P&gt;Reading this article:&amp;nbsp;&lt;A href="https://stats.idre.ucla.edu/wp-content/uploads/2016/02/bt185.pdf" target="_blank"&gt;https://stats.idre.ucla.edu/wp-content/uploads/2016/02/bt185.pdf&lt;/A&gt;&amp;nbsp;will help you understand secrets of macro quoting.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;All the best&lt;/P&gt;
&lt;P&gt;Bart&lt;/P&gt;</description>
    <pubDate>Mon, 21 Jun 2021 08:38:19 GMT</pubDate>
    <dc:creator>yabwon</dc:creator>
    <dc:date>2021-06-21T08:38:19Z</dc:date>
    <item>
      <title>Help needed in understanding %str function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Help-needed-in-understanding-str-function/m-p/749188#M235368</link>
      <description>&lt;P&gt;Dear,&lt;/P&gt;
&lt;P&gt;I came across a situation where I used macro variables&amp;nbsp; in my pgm created by using macro function %str. I got error. when I&amp;nbsp; removed %str function I did not get error. Please help me understand. Thank you&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I created 4 macro variables. Two using %str function. Other two not. When I run&amp;nbsp; %one macro using macro variables created using %str function. I am getting error. But when i run with other two, I am not. Please help.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%let gm_ba                       = %str(03)                                                              ;
%let gm_snum                     = %str(a0310)                                                      ;
%let gm_ca                       = 03                                                              ;
%let gm_tnum                     = a0310                                                           ;
data aaa;
input a $ b;
datalines;
a 1 
b 2
c 3
;
%macro one;
data c&amp;amp;gm_ba&amp;amp;gm_snum.01;
set aaa;
run;
%mend;&lt;BR /&gt;
%one;&lt;BR /&gt;
%macro one;
data c&amp;amp;gm_ca&amp;amp;gm_tnum.01;
set aaa;
run;
%mend;&lt;BR /&gt;
%one;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Mon, 21 Jun 2021 06:27:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Help-needed-in-understanding-str-function/m-p/749188#M235368</guid>
      <dc:creator>knveraraju91</dc:creator>
      <dc:date>2021-06-21T06:27:32Z</dc:date>
    </item>
    <item>
      <title>Re: Help needed in understanding %str function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Help-needed-in-understanding-str-function/m-p/749190#M235370</link>
      <description>&lt;P&gt;Always look at the log.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;You'll see that quoting the macro variable using %str()&amp;nbsp; adds non-printable characters.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Use the %unquote() function in your data step.&lt;/P&gt;</description>
      <pubDate>Mon, 21 Jun 2021 06:52:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Help-needed-in-understanding-str-function/m-p/749190#M235370</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2021-06-21T06:52:22Z</dc:date>
    </item>
    <item>
      <title>Re: Help needed in understanding %str function</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Help-needed-in-understanding-str-function/m-p/749200#M235378</link>
      <description>&lt;P&gt;Reading this article:&amp;nbsp;&lt;A href="https://stats.idre.ucla.edu/wp-content/uploads/2016/02/bt185.pdf" target="_blank"&gt;https://stats.idre.ucla.edu/wp-content/uploads/2016/02/bt185.pdf&lt;/A&gt;&amp;nbsp;will help you understand secrets of macro quoting.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;All the best&lt;/P&gt;
&lt;P&gt;Bart&lt;/P&gt;</description>
      <pubDate>Mon, 21 Jun 2021 08:38:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Help-needed-in-understanding-str-function/m-p/749200#M235378</guid>
      <dc:creator>yabwon</dc:creator>
      <dc:date>2021-06-21T08:38:19Z</dc:date>
    </item>
  </channel>
</rss>

