<?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: using a macro in a library declaration in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/using-a-macro-in-a-library-declaration/m-p/588409#M168155</link>
    <description>&lt;P&gt;enclose in double quotes for macro variable to resolve&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt; 

%let portfolio = samplename;

libname out "/folder1/folder2/folder3/&amp;amp;portfolio";&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Thu, 12 Sep 2019 23:52:37 GMT</pubDate>
    <dc:creator>novinosrin</dc:creator>
    <dc:date>2019-09-12T23:52:37Z</dc:date>
    <item>
      <title>using a macro in a library declaration</title>
      <link>https://communities.sas.com/t5/SAS-Programming/using-a-macro-in-a-library-declaration/m-p/588405#M168152</link>
      <description>&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Hello,&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;&amp;nbsp;&amp;nbsp; When I try to run the following code it says library does not exist. I am doing something wrong in the libname out statement. But not sure what. Please advice. &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Thanks &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;in advance. &lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;%let&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; portfolio = samplename;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;libname&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt; out &lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;'/folder1/folder2/folder3/&amp;amp;portfolio'&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;proc&lt;/STRONG&gt;&lt;/FONT&gt; &lt;STRONG&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;import&lt;/FONT&gt;&lt;/STRONG&gt; &lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Out&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;=out.BT_EOP_Balance_import &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;datafile&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;= &lt;/FONT&gt;&lt;FONT color="#800080" face="Courier New" size="3"&gt;"/folder1/folder2/folder3/&amp;amp;portfolio/excelfile1_&amp;amp;portfolio..xlsx"&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Dbms&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;=xlsx &lt;/FONT&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;replace&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#0000ff" face="Courier New" size="3"&gt;Sheet&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;=BT_EOP_Balance;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080" face="Courier New" size="3"&gt;&lt;STRONG&gt;run&lt;/STRONG&gt;&lt;/FONT&gt;&lt;FONT face="Courier New" size="3"&gt;;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 12 Sep 2019 23:26:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/using-a-macro-in-a-library-declaration/m-p/588405#M168152</guid>
      <dc:creator>ubshams</dc:creator>
      <dc:date>2019-09-12T23:26:42Z</dc:date>
    </item>
    <item>
      <title>Re: using a macro in a library declaration</title>
      <link>https://communities.sas.com/t5/SAS-Programming/using-a-macro-in-a-library-declaration/m-p/588409#M168155</link>
      <description>&lt;P&gt;enclose in double quotes for macro variable to resolve&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt; 

%let portfolio = samplename;

libname out "/folder1/folder2/folder3/&amp;amp;portfolio";&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 12 Sep 2019 23:52:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/using-a-macro-in-a-library-declaration/m-p/588409#M168155</guid>
      <dc:creator>novinosrin</dc:creator>
      <dc:date>2019-09-12T23:52:37Z</dc:date>
    </item>
    <item>
      <title>Re: using a macro in a library declaration</title>
      <link>https://communities.sas.com/t5/SAS-Programming/using-a-macro-in-a-library-declaration/m-p/588515#M168209</link>
      <description>&lt;P&gt;Thanks that worked&lt;/P&gt;</description>
      <pubDate>Fri, 13 Sep 2019 13:30:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/using-a-macro-in-a-library-declaration/m-p/588515#M168209</guid>
      <dc:creator>ubshams</dc:creator>
      <dc:date>2019-09-13T13:30:25Z</dc:date>
    </item>
  </channel>
</rss>

