<?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: libname doesn't exist in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751113#M236398</link>
    <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/202329"&gt;@GN0001&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;Yes, I misspelled the name of the folder.&lt;/P&gt;
&lt;P&gt;I didn't know we shouldn't create a libname for a folder that already exist in SAS. Thanks for your input.&lt;/P&gt;
&lt;P&gt;Anyway, it doesn't allow me to read from the file that already exists in SAS:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;data mydata;
set membertable (obs=100);
Run;&lt;/PRE&gt;
&lt;P&gt;The error I get is:&lt;/P&gt;
&lt;P&gt;File work.membertable doesn't exist.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The folder is in SAS, but the backend is unix server.&lt;/P&gt;
&lt;P&gt;Blue blue&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;What is the file you are trying to access?&amp;nbsp; If you have a SAS datasets on disk you can either assign a libref that points to the directory that contains the file using a LIBNAME statement or LIBNAME() function and reference the file using a "two level" name.&amp;nbsp; (Note if you already have a defined libref just use that libref)&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;libname mylib 'mydirectoryname';
data mydata;
  set mylib.membertable (obs=100);
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Or just reference the file by using its physical name in quotes.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data mydata;
  set "mydirectoryname/membertable" (obs=100);
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Note that SAS will silently make a libref pointing to the directory for you without telling you.&lt;/P&gt;</description>
    <pubDate>Wed, 30 Jun 2021 04:23:29 GMT</pubDate>
    <dc:creator>Tom</dc:creator>
    <dc:date>2021-06-30T04:23:29Z</dc:date>
    <item>
      <title>libname doesn't exist</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751023#M236335</link>
      <description>&lt;P&gt;Hello team,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I created a libname for a file which exists in SAS.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I get an error message that the libname doesn't exist.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Should I create a libname for a file which already exist in SAS?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please advise me.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Blue blue&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jun 2021 17:52:18 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751023#M236335</guid>
      <dc:creator>GN0001</dc:creator>
      <dc:date>2021-06-29T17:52:18Z</dc:date>
    </item>
    <item>
      <title>Re: libname doesn't exist</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751035#M236342</link>
      <description>&lt;BLOCKQUOTE&gt;
&lt;P&gt;I created a libname for a file which exists in SAS.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I get an error message that the libname doesn't exist.&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Not sure what you mean here. If the file is already in SAS, it doesn't need a libname. (Libnames are for folders, not files) Please show us your code, and a screen capture that shows the file as it appears in SAS.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jun 2021 18:31:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751035#M236342</guid>
      <dc:creator>PaigeMiller</dc:creator>
      <dc:date>2021-06-29T18:31:05Z</dc:date>
    </item>
    <item>
      <title>Re: libname doesn't exist</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751036#M236343</link>
      <description>&lt;P&gt;Unless your want to use a libref engine that access many members in a single file (like XPORT or XLSX) then the libname should point to the folder that contains the file not the actual file that is the SAS dataset.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;So if SAS is running on Unix and you have a file named mydata.sas7bdat in a directory named \home\myname\myfiles then your SAS code might look like:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;libname XXX '\home\myname\myfiles';
proc contents data=xxx.mydata;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jun 2021 18:36:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751036#M236343</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2021-06-29T18:36:12Z</dc:date>
    </item>
    <item>
      <title>Re: libname doesn't exist</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751041#M236348</link>
      <description>&lt;P&gt;Please post the complete log of the LIBNAME statement.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jun 2021 18:55:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751041#M236348</guid>
      <dc:creator>Kurt_Bremser</dc:creator>
      <dc:date>2021-06-29T18:55:38Z</dc:date>
    </item>
    <item>
      <title>Re: libname doesn't exist</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751044#M236349</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/202329"&gt;@GN0001&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hello team,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I created a libname for a file which exists in SAS.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I get an error message that the libname doesn't exist.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Should I create a libname for a file which already exist in SAS?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Please advise me.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Blue blue&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;You did something wrong. Show your work if you want to know where specifically you went wrong.&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jun 2021 19:03:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751044#M236349</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2021-06-29T19:03:38Z</dc:date>
    </item>
    <item>
      <title>Re: libname doesn't exist</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751052#M236354</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;Yes, I misspelled the name of the folder.&lt;/P&gt;
&lt;P&gt;I didn't know we shouldn't create a libname for a folder that already exist in SAS. Thanks for your input.&lt;/P&gt;
&lt;P&gt;Anyway, it doesn't allow me to read from the file that already exists in SAS:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;data mydata;
set membertable (obs=100);
Run;&lt;/PRE&gt;
&lt;P&gt;The error I get is:&lt;/P&gt;
&lt;P&gt;File work.membertable doesn't exist.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The folder is in SAS, but the backend is unix server.&lt;/P&gt;
&lt;P&gt;Blue blue&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jun 2021 20:03:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751052#M236354</guid>
      <dc:creator>GN0001</dc:creator>
      <dc:date>2021-06-29T20:03:19Z</dc:date>
    </item>
    <item>
      <title>Re: libname doesn't exist</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751053#M236355</link>
      <description>&lt;P&gt;one of the folders in the path in the libname is misspelled.&lt;/P&gt;
&lt;P&gt;Instead of QA, I spelled AQ.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Blue Blue&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jun 2021 20:14:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751053#M236355</guid>
      <dc:creator>GN0001</dc:creator>
      <dc:date>2021-06-29T20:14:04Z</dc:date>
    </item>
    <item>
      <title>Re: libname doesn't exist</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751055#M236356</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;Still, I can't read the file if I don't create a libname statement. SAS is running on unix.&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;blue blue&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jun 2021 20:17:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751055#M236356</guid>
      <dc:creator>GN0001</dc:creator>
      <dc:date>2021-06-29T20:17:45Z</dc:date>
    </item>
    <item>
      <title>Re: libname doesn't exist</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751073#M236368</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;Actually the data exists in SAS but without libname, I can't read from that dataset.&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Blue Blue&lt;/P&gt;</description>
      <pubDate>Tue, 29 Jun 2021 21:54:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751073#M236368</guid>
      <dc:creator>GN0001</dc:creator>
      <dc:date>2021-06-29T21:54:17Z</dc:date>
    </item>
    <item>
      <title>Re: libname doesn't exist</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751113#M236398</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/202329"&gt;@GN0001&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;Yes, I misspelled the name of the folder.&lt;/P&gt;
&lt;P&gt;I didn't know we shouldn't create a libname for a folder that already exist in SAS. Thanks for your input.&lt;/P&gt;
&lt;P&gt;Anyway, it doesn't allow me to read from the file that already exists in SAS:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;data mydata;
set membertable (obs=100);
Run;&lt;/PRE&gt;
&lt;P&gt;The error I get is:&lt;/P&gt;
&lt;P&gt;File work.membertable doesn't exist.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The folder is in SAS, but the backend is unix server.&lt;/P&gt;
&lt;P&gt;Blue blue&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;What is the file you are trying to access?&amp;nbsp; If you have a SAS datasets on disk you can either assign a libref that points to the directory that contains the file using a LIBNAME statement or LIBNAME() function and reference the file using a "two level" name.&amp;nbsp; (Note if you already have a defined libref just use that libref)&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;libname mylib 'mydirectoryname';
data mydata;
  set mylib.membertable (obs=100);
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Or just reference the file by using its physical name in quotes.&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data mydata;
  set "mydirectoryname/membertable" (obs=100);
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;Note that SAS will silently make a libref pointing to the directory for you without telling you.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Jun 2021 04:23:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751113#M236398</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2021-06-30T04:23:29Z</dc:date>
    </item>
    <item>
      <title>Re: libname doesn't exist</title>
      <link>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751262#M236464</link>
      <description>&lt;P&gt;Not technically correct you can reference a file with the full path.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data want;
set '/home/fkhurshed/Demo1/class.sas7bdat';
run;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/202329"&gt;@GN0001&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;Actually the data exists in SAS but without libname, I can't read from that dataset.&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Blue Blue&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Jun 2021 14:14:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/libname-doesn-t-exist/m-p/751262#M236464</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2021-06-30T14:14:50Z</dc:date>
    </item>
  </channel>
</rss>

