Every time I try to run my /home/u63993525/EPG1V2/data in LIBNAME, I always get an error. I think it is gone entirely. Any way to get it back?
EDIT from output: NOTE: Library MYDATA does not exist. I cannot run anything SAS right now. I am running the cloud-based version (SAS for Educators)
In that case go back to Activity 2.04 and redo it and make sure it works and you have saved the libname.sas program (and you know how to find it again).
Please post your SAS log of the LIBNAME statement and error so we hve a better idea of what is happening.
LIBNAME mydata "C:/home/u63993525/EPG1V2/data";
It's one way I have tried. I have tried several other ways but it does not exist.
If this is tried in SAS On Demand, it cannot work. UNIX does not have drive letters like Windows.
Are you really running SAS on Windows such that C: makes sense? If you are running on Unix you want to start your path with the root node (the / ).
LIBNAME mydata "/home/u63993525/EPG1V2/data";
Do you have some way you can check if the directory actually exists on the machine where SAS itself is running? Note if you are using SAS/Studio or Enterprise Guide to write and submit your SAS programs then SAS itself is most likely running on a different machine than the one you are using directly.
Also remember that on Unix case of letter matter in filenames. So these are all different paths:
/home/u63993525/EPG1V2/data /home/u63993525/EPG1V2/Data /home/U63993525/EPG1V2/data /home/u63993525/epg1v2/data
What OS does your SAS server run on? I suggest you check with your SAS administrator or IT help desk to confirm if your folder still exists or not. Typically server storage is regularly backed up so you could request your folder be restored.
I am running it on SAS for Educators (cloud-based)
@JJ2025 wrote:
I am running it on SAS for Educators (cloud-based)
Which means UNIX as operating system, so you need to use UNIX filename syntax.
Hint: right-click on the directory in your navigation pane and copy the actual path from the properties. It will start with /home.
I am trying to practice doing this:
If necessary, start SAS Studio. Open p103p01.sas from the practices folder and do the following:
Complete the PROC PRINT statement to list the first 20 observations in pg1.np_summary.
Add a VAR statement to include only the following variables: Reg, Type, ParkName, DayVisits, TentCampers, and RVCampers.
Highlight the step and run the selected code.
Do you observe any possible inconsistencies in the data?
Reminder: If you restarted your SAS session, you must first run the libname.sas program created in Activity 2.04.
Every time I try to run it again, it's just error after error after error
EDIT: I tried moving to Where statements and still get this error: "ERROR: Libref PG1 is not assigned."
In that case go back to Activity 2.04 and redo it and make sure it works and you have saved the libname.sas program (and you know how to find it again).
Thank you for attempting to help, I did that, and it did not work.
You are missing a semicolon on your LIBNAME statement.
It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.
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.
Ready to level-up your skills? Choose your own adventure.