BookmarkSubscribeRSS Feed
nimaljo
Calcite | Level 5
Can someone please help?
I am also getting the above error.
libname PG1 "&path";
NOTE: Library PG1 does not exist.
2 REPLIES 2
Mark2010
SAS Employee

@nimaljo 

 

Can you please share:

  • The code that you submitted to create the library.
  • The complete log of the error.
  • The environment that you are using: SAS On Demand for Academics or a locally installed version of SAS?

 

Cynthia_sas
Diamond | Level 26

Hi:
In our Programming 1 class, with a LIBNAME statement like this, we would expect to see a %LET statement before the LIBNAME statement. Something like this (several possibilities):
%let path=s:\workshop\EPG1V2\data;
or
%let path=/home/u12345678/EPG1V2/data;
or
%let path=%sysfunc(pathname(WORK)); /* this only works on SAS Enterprise Guide */
then your LIBNAME:
libname pg1 "&path";

But, as @Mark2010 pointed out, without seeing ALL of your code, including your %LET statement it is hard to comment. If you are running Programming 1 in your own version of Enterprise Guide, we automatically create the &PATH helper variable for you. The fact that &path is not working either implies that you are not using Enterprise Guide or you did not get to the place in class yet where we have you create &PATH helper variable.


Can you also clarify where you're working in the class -- by providing the lesson number and the activity, demo or practice that you're doing?


Thanks, in advance,
Cynthia

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

Register Now

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 2 replies
  • 732 views
  • 2 likes
  • 3 in conversation