<?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 libname won't call the macro variable in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/libname-won-t-call-the-macro-variable/m-p/751244#M236457</link>
    <description>&lt;P&gt;I am running the following code, but when calling the macro-variable I just created, "dir", &lt;STRONG&gt;libname&lt;/STRONG&gt; does not work. As you can see, the "dir" macro-variable is the EXACT same path used to create the library testa, which successfully creates the library.&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;libname testa 'C:\Users' ;
%let dir = C:\Users;
libname testb '&amp;amp;dir';

libname testc '&amp;amp;dir.';

libname testd ' &amp;amp;dir ';

libname teste ' &amp;amp;dir. ';&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Every time I run this code, I get the same 'NOTE: Library TEST_X_ does not exist.' message for each test, i.e., TESTB, TESTC, TESTD, &amp;amp; TESTE. (For brevity, I did not include ALL of those error messages.)&lt;/P&gt;&lt;HR /&gt;&lt;P&gt;159 libname testa 'C:\Users' ;&lt;BR /&gt;&lt;FONT color="#0000FF"&gt;NOTE: Libref TESTA was successfully assigned as follows:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF"&gt;Engine: V9&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF"&gt;Physical Name: C:\Users&lt;/FONT&gt;&lt;BR /&gt;160 %let dir = C:\Users;&lt;BR /&gt;161 libname testb '&amp;amp;dir';&lt;BR /&gt;&lt;FONT color="#0000FF"&gt;NOTE: Library TESTB does not exist.&lt;/FONT&gt;&lt;/P&gt;&lt;HR /&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;Your help is appreciated!&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Wed, 30 Jun 2021 13:45:20 GMT</pubDate>
    <dc:creator>ericdrosano</dc:creator>
    <dc:date>2021-06-30T13:45:20Z</dc:date>
    <item>
      <title>libname won't call the macro variable</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-won-t-call-the-macro-variable/m-p/751244#M236457</link>
      <description>&lt;P&gt;I am running the following code, but when calling the macro-variable I just created, "dir", &lt;STRONG&gt;libname&lt;/STRONG&gt; does not work. As you can see, the "dir" macro-variable is the EXACT same path used to create the library testa, which successfully creates the library.&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;libname testa 'C:\Users' ;
%let dir = C:\Users;
libname testb '&amp;amp;dir';

libname testc '&amp;amp;dir.';

libname testd ' &amp;amp;dir ';

libname teste ' &amp;amp;dir. ';&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Every time I run this code, I get the same 'NOTE: Library TEST_X_ does not exist.' message for each test, i.e., TESTB, TESTC, TESTD, &amp;amp; TESTE. (For brevity, I did not include ALL of those error messages.)&lt;/P&gt;&lt;HR /&gt;&lt;P&gt;159 libname testa 'C:\Users' ;&lt;BR /&gt;&lt;FONT color="#0000FF"&gt;NOTE: Libref TESTA was successfully assigned as follows:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF"&gt;Engine: V9&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#0000FF"&gt;Physical Name: C:\Users&lt;/FONT&gt;&lt;BR /&gt;160 %let dir = C:\Users;&lt;BR /&gt;161 libname testb '&amp;amp;dir';&lt;BR /&gt;&lt;FONT color="#0000FF"&gt;NOTE: Library TESTB does not exist.&lt;/FONT&gt;&lt;/P&gt;&lt;HR /&gt;&lt;P&gt;&lt;FONT color="#000000"&gt;Your help is appreciated!&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Jun 2021 13:45:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-won-t-call-the-macro-variable/m-p/751244#M236457</guid>
      <dc:creator>ericdrosano</dc:creator>
      <dc:date>2021-06-30T13:45:20Z</dc:date>
    </item>
    <item>
      <title>Re: libname won't call the macro variable</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-won-t-call-the-macro-variable/m-p/751245#M236458</link>
      <description>&lt;P&gt;The macro processor ignores text that is bounded on the outside by single quotes.&lt;/P&gt;
&lt;P&gt;Use double quotes instead if you want the macro processor to see the macro variable reference.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;libname testa 'C:\Users' ;
%let dir = C:\Users;
libname testb "&amp;amp;dir";&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 30 Jun 2021 13:47:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-won-t-call-the-macro-variable/m-p/751245#M236458</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2021-06-30T13:47:55Z</dc:date>
    </item>
    <item>
      <title>Re: libname won't call the macro variable</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-won-t-call-the-macro-variable/m-p/751254#M236461</link>
      <description>Double quotes versus single quotes... got me crying over here!!!&lt;BR /&gt;Thank you mightily!</description>
      <pubDate>Wed, 30 Jun 2021 14:01:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-won-t-call-the-macro-variable/m-p/751254#M236461</guid>
      <dc:creator>ericdrosano</dc:creator>
      <dc:date>2021-06-30T14:01:25Z</dc:date>
    </item>
  </channel>
</rss>

