BookmarkSubscribeRSS Feed
☑ This topic is solved. Need further help from the community? Please sign in and ask a new question.
eiraduku
Fluorite | Level 6

Good evening

I am facing a difficulty on running libname.sas to get PG2 library.

I am having an error on submitting libname and when checking on libraries I see that PG2 is there, but I can run the other SAS codes because libname.sas' notes that PG2 does not exist.

 

libname.sas codes

%let path=s:/workshop/EPG2V2/data;

/**********************************************/
/* DO NOT EDIT THE CODE BELOW */
/**********************************************/

libname PG2 "&path";

 

 

notes:

84 libname PG2 "&path";
NOTE: Library PG2 does not exist.

 

 

Any help

 

1 ACCEPTED SOLUTION

Accepted Solutions
PaigeMiller
Diamond | Level 26

@eiraduku wrote:

 

libname.sas codes

%let path=s:/workshop/EPG2V2/data;

/**********************************************/
/* DO NOT EDIT THE CODE BELOW */
/**********************************************/

libname PG2 "&path";

 

notes:

84 libname PG2 "&path";
NOTE: Library PG2 does not exist.


The name of the folder in the LIBNAME statement is incorrect. The is no such folder as s:/workshop/EPG2V2/data and so SAS cannot find this folder which doesn't exist (and why do you need a macro variable for this anyway?)

 

I'm guessing, because you didn't provide those details, that you are using a server version of SAS, perhaps SAS Studio, which cannot access your computer's local drives, such as the S: drive. In that case, you would have to upload the appropriate data set(s) to the server, and then access them via the server folder name in the LIBNAME statement.

--
Paige Miller

View solution in original post

2 REPLIES 2
PaigeMiller
Diamond | Level 26

@eiraduku wrote:

 

libname.sas codes

%let path=s:/workshop/EPG2V2/data;

/**********************************************/
/* DO NOT EDIT THE CODE BELOW */
/**********************************************/

libname PG2 "&path";

 

notes:

84 libname PG2 "&path";
NOTE: Library PG2 does not exist.


The name of the folder in the LIBNAME statement is incorrect. The is no such folder as s:/workshop/EPG2V2/data and so SAS cannot find this folder which doesn't exist (and why do you need a macro variable for this anyway?)

 

I'm guessing, because you didn't provide those details, that you are using a server version of SAS, perhaps SAS Studio, which cannot access your computer's local drives, such as the S: drive. In that case, you would have to upload the appropriate data set(s) to the server, and then access them via the server folder name in the LIBNAME statement.

--
Paige Miller
eiraduku
Fluorite | Level 6

Thanks.

The issue was on the path to data.

 

 

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

LIBNAME 101

Follow along as SAS technical trainer Dominique Weatherspoon expertly answers all your questions about SAS Libraries.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 2 replies
  • 736 views
  • 0 likes
  • 2 in conversation