<?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: Error resolving macro variables in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Error-resolving-macro-variables/m-p/614961#M179822</link>
    <description>&lt;P&gt;When you execute code that has a macro variable in it, the macro variable is replaced by its value, and &lt;STRONG&gt;this must result in legal valid working SAS code&lt;/STRONG&gt;.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So in your case,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;b=&amp;amp;lc_entity_currency.;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;when executed, becomes&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;b=5801_EU 2713_EU 6001_PL;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Can you spot the error now?&lt;/P&gt;</description>
    <pubDate>Fri, 03 Jan 2020 13:30:32 GMT</pubDate>
    <dc:creator>PaigeMiller</dc:creator>
    <dc:date>2020-01-03T13:30:32Z</dc:date>
    <item>
      <title>Error resolving macro variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-resolving-macro-variables/m-p/614958#M179820</link>
      <description>&lt;P&gt;Could you please help resolve the error below?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;27         %let lc_entity_currency=5801_EU 2713_EU 6001_PL;
28         data _null_;
29         b=&amp;amp;lc_entity_currency.;
SYMBOLGEN:  Macro variable LC_ENTITY_CURRENCY resolves to 5801_EU 2713_EU 6001_PL
NOTE: Line generated by the macro variable "LC_ENTITY_CURRENCY".
29         5801_EU 2713_EU 6001_PL
               ___
               388
               76
ERROR 388-185: Expecting an arithmetic operator.

ERROR 76-322: Syntax error, statement will be ignored.

30         run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 03 Jan 2020 13:15:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-resolving-macro-variables/m-p/614958#M179820</guid>
      <dc:creator>David_Billa</dc:creator>
      <dc:date>2020-01-03T13:15:25Z</dc:date>
    </item>
    <item>
      <title>Re: Error resolving macro variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-resolving-macro-variables/m-p/614960#M179821</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/292396"&gt;@David_Billa&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Since the macro variable contains letters, you should add quotes (it cannot be considered a numeric)&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;b="&amp;amp;lc_entity_currency.";&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 03 Jan 2020 13:19:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-resolving-macro-variables/m-p/614960#M179821</guid>
      <dc:creator>ed_sas_member</dc:creator>
      <dc:date>2020-01-03T13:19:01Z</dc:date>
    </item>
    <item>
      <title>Re: Error resolving macro variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-resolving-macro-variables/m-p/614961#M179822</link>
      <description>&lt;P&gt;When you execute code that has a macro variable in it, the macro variable is replaced by its value, and &lt;STRONG&gt;this must result in legal valid working SAS code&lt;/STRONG&gt;.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So in your case,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;b=&amp;amp;lc_entity_currency.;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;when executed, becomes&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;b=5801_EU 2713_EU 6001_PL;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Can you spot the error now?&lt;/P&gt;</description>
      <pubDate>Fri, 03 Jan 2020 13:30:32 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-resolving-macro-variables/m-p/614961#M179822</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2020-01-03T13:30:32Z</dc:date>
    </item>
    <item>
      <title>Re: Error resolving macro variables</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-resolving-macro-variables/m-p/615040#M179862</link>
      <description>&lt;PRE&gt;&lt;CODE class=" language-sas"&gt; %let lc_entity_currency=%str(5801_EU 2713_EU 6001_PL);
data _null_;
b=symget('lc_entity_currency');
put 'b=' b;
run;
 %let lc_entity_currency="5801_EU 2713_EU 6001_PL";
data _null_;
c=resolve(&amp;amp;lc_entity_currency);
put 'c=' c;

run;

&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 03 Jan 2020 19:19:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-resolving-macro-variables/m-p/615040#M179862</guid>
      <dc:creator>ghosh</dc:creator>
      <dc:date>2020-01-03T19:19:46Z</dc:date>
    </item>
  </channel>
</rss>

