<?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: Macro Variable Resolution in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Macro-Variable-Resolution/m-p/281195#M56970</link>
    <description>Try double quotes instead of single quotes</description>
    <pubDate>Wed, 29 Jun 2016 18:12:40 GMT</pubDate>
    <dc:creator>JohnHoughton</dc:creator>
    <dc:date>2016-06-29T18:12:40Z</dc:date>
    <item>
      <title>Macro Variable Resolution</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Macro-Variable-Resolution/m-p/281186#M56967</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hi. I have this reference to &amp;amp;ZIP5 that isn't resolving. It's inside of my Macro named Loopy, does this keep it from resolving? &amp;nbsp;Or maybe something to do with the statements being in quotes?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any help would be appreciated.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;MPRINT(LOOPY):   * Create unique index (if not exist), to meet the criteria that only one record (imb) per ;
MPRINT(LOOPY):   * rule is kept and counted in the data ;
MPRINT(LOOPY):   data _null_;
MPRINT(LOOPY):   set sashelp.vmember (where=(Libname='WORK' and memname='FINALDATA&amp;amp;ZIP5'));
MPRINT(LOOPY):   if upcase(index)='NO' then call execute('proc datasets; modify finaldata&amp;amp;ZIP5; index create imb_code /unique;
run; quit;');
MPRINT(LOOPY):   run;

NOTE: There were 0 observations read from the data set SASHELP.VMEMBER.
      WHERE (Libname='WORK') and (memname='FINALDATA&amp;amp;ZIP5');
NOTE: DATA statement used (Total process time):
      real time           0.01 seconds
      cpu time            0.00 seconds

&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 29 Jun 2016 18:00:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Macro-Variable-Resolution/m-p/281186#M56967</guid>
      <dc:creator>buechler66</dc:creator>
      <dc:date>2016-06-29T18:00:52Z</dc:date>
    </item>
    <item>
      <title>Re: Macro Variable Resolution</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Macro-Variable-Resolution/m-p/281193#M56968</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;No way to know for sure until we get to see the full code. But a common oversight is to determine the scope of a variable. If it is not defined as global inside a macro the variable reference may not get resolved.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%GLOBAL zip5;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;But to get the full picture we need the code.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;- Jan&lt;/P&gt;</description>
      <pubDate>Wed, 29 Jun 2016 18:11:27 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Macro-Variable-Resolution/m-p/281193#M56968</guid>
      <dc:creator>jklaverstijn</dc:creator>
      <dc:date>2016-06-29T18:11:27Z</dc:date>
    </item>
    <item>
      <title>Re: Macro Variable Resolution</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Macro-Variable-Resolution/m-p/281195#M56970</link>
      <description>Try double quotes instead of single quotes</description>
      <pubDate>Wed, 29 Jun 2016 18:12:40 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Macro-Variable-Resolution/m-p/281195#M56970</guid>
      <dc:creator>JohnHoughton</dc:creator>
      <dc:date>2016-06-29T18:12:40Z</dc:date>
    </item>
    <item>
      <title>Re: Macro Variable Resolution</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Macro-Variable-Resolution/m-p/281198#M56973</link>
      <description>Ah yes. Doh!</description>
      <pubDate>Wed, 29 Jun 2016 18:13:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Macro-Variable-Resolution/m-p/281198#M56973</guid>
      <dc:creator>jklaverstijn</dc:creator>
      <dc:date>2016-06-29T18:13:24Z</dc:date>
    </item>
  </channel>
</rss>

