BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
BaileyY
Obsidian | Level 7

Hi-

 

New to SAS Enterprise Guide and trying to understand how to use EG in the Programming window to access my dataset stored on our SAS server.  Data is located under Servers/SASApp/Libraries/Medic1 and the dataset name is: RiverdaleMed

 

Wrote this:  data a; Set Medic1.RiverdaleMed; where location in ('15');run;  

 

I am getting error message in my log telling me  ERROR: Libref Medic1 is not assigned.   

 

Can anyone help me get started?  Thanks in advance!!

 

1 ACCEPTED SOLUTION

Accepted Solutions
SASKiwi
PROC Star

There's an EG Task to upload local datasets to the SAS server: Tasks / Data / Upload Data Files to Server.

 

You can't reference your local PC drive from the SAS server in code without a lot of IT admin, and it wouldn't be very efficient anyway as you say.

 

You may also want to consider asking your IT Admin to set up a permanent SAS server LIBREF for you, particularly if it is being shared with other users. That means it is automatically set up in EG when you connect to the SAS server and you don't need to code for it yourself.

View solution in original post

7 REPLIES 7
SASKiwi
PROC Star

Before you can read your dataset you need to assign the LIBREF medic1 pointing at your SAS library:

libname medic1 '//Servers/SASApp/Libraries/Medic1';

 

 

BaileyY
Obsidian | Level 7
Hi- Thanks for responding. I am now getting a green NOTE message telling me Library medic1 does not exist? Any insights?
SASKiwi
PROC Star

Please post the SAS log containing the LIBNAME statement and any notes. Did it assign successfully?

BaileyY
Obsidian | Level 7

25 libname medic1 '//Servers/SASApp/Libraries/medic1';
NOTE: Library medic1 does not exist.

26
27 GOPTIONS NOACCESSIBLE;
28 %LET _CLIENTTASKLABEL=;
29 %LET _CLIENTPROCESSFLOWNAME=;
30 %LET _CLIENTPROJECTPATH=;
31 %LET _CLIENTPROJECTNAME=;
32 %LET _SASPROGRAMFILE=;
33
34 ;*';*";*/;quit;run;
35 ODS _ALL_ CLOSE;
36
37
38 QUIT; RUN;
39

SASKiwi
PROC Star

It looks like the path //Servers/SASApp/Libraries/medic1 is incorrect. Please talk to your SAS admin to find out what the correct path is. Usually the first bit is the server name like this //ServerName which may go on the front of the path you have. Also try this: /Servers/SASApp/Libraries/medic1.

BaileyY
Obsidian | Level 7

Ok. Thanks. 

 

One more question:

 

What about datasets in my local drive?  Must all the datasets reside on the Server to use EG within SAS Server?   OR can I use a reference library in my local drive:  D:\1OrigDataSets\March\Oceanside and run my code in the Program Window within the Server.  

 

Definitely, the server will be able to process all the merge/sorts/appends much quicker than if it was in my local drive.  Any info?  

 

Thank you so much for responding!

 

SASKiwi
PROC Star

There's an EG Task to upload local datasets to the SAS server: Tasks / Data / Upload Data Files to Server.

 

You can't reference your local PC drive from the SAS server in code without a lot of IT admin, and it wouldn't be very efficient anyway as you say.

 

You may also want to consider asking your IT Admin to set up a permanent SAS server LIBREF for you, particularly if it is being shared with other users. That means it is automatically set up in EG when you connect to the SAS server and you don't need to code for it yourself.

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

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
  • 7 replies
  • 3396 views
  • 1 like
  • 2 in conversation