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

libname libsas "folders/myshortcuts/s2/";
data libsas.account;
account_id = 00001;
firtname ='John';
lastname ='Liu';
run;

 

ERROR: Library LIBSAS does not exist.

 

 

 

Please help me with code,I am a beginner and this library thing is becoming a trouble for me.

I have attached the sceenshot of log as well.


error_screenshot.png
1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User

The path is incorrect, the / in front of folders is missing. 

View solution in original post

9 REPLIES 9
Yavuz
Quartz | Level 8
1.) Please write full path. Like
Libname mylib "D:\mydata";

2.) If account_id is string it must be like "00001"

3.) Are you working on Sas base or sas EG,
If sas Eg server maybe you have an authorization problem
s_m
Obsidian | Level 7 s_m
Obsidian | Level 7

thanks for your help

but actually i have defined s2 in shared folder so it is coming under my shortcuts in sas studio so i can refer it as /folders/myshortcuts/s2.So please help me out what went wrong

 

Reeza
Super User

The path is incorrect, the / in front of folders is missing. 

Reeza
Super User

Are you using an English browser? 

I think something may be wrong earlier and carrying over. 

 

Can you start a new session, restart your VM and run only the code shown. 

s_m
Obsidian | Level 7 s_m
Obsidian | Level 7

I am using SAS Studio (SAS University Edition)

I started the new session but error is still the same.

I am unable to assign a libref through libname statement.

 

libname libsas "/folders/myshortcuts/s2/";
data work.out;
set libsas.abc;

run;

 

ERROR:

File LIBSAS.ABC.DATA does not exist

 

abc.xlsx data is physical present under S2 and is visible in myshorts in sas studio.Please refe the screenshot attached.

 

Please help me ith this.

.

 


error_screenshot2.png
Reeza
Super User

Did the solution suggested not work?

s_m
Obsidian | Level 7 s_m
Obsidian | Level 7

Thanks Reeza it worked but I am facing another issue which I have already described in previous reply.Please help me on that.

Thanks in advance

kaverisonu1
Fluorite | Level 6

You cannot use excel file directly as a dataset. You need to first import teh excel file using proc import as below.

 

proc import datafile= "<path>"  out=<dataset name in sas>

sheet ="<sheetname if specific sheet needs to be imported>" ;

run;

 

post this you acn use your dataset.

Another way would be using DDE in sas.

 

s_m
Obsidian | Level 7 s_m
Obsidian | Level 7

thanks a lot Kaverisonu for your help.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 9 replies
  • 18127 views
  • 1 like
  • 4 in conversation