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

Hi

I am trying to read a file stored in my desktop.

i created the libname zo 'c:\users\desktop';

proc print data=zo.saspractice;

run;

 

the system says library zo.saspractice does not exist

 

 

1 ACCEPTED SOLUTION

Accepted Solutions
ballardw
Super User

Most SAS procedures use files in proprietary SAS file formats. If you data is in a text, csv, xls, xlsx or other file format then the data has to be imported into SAS so the values are in the right file format. Until you have done that using either a wizard, task or code written to read the data there is not a SAS formatted data set and so the "the data set does not exist".

 

The name SASPRACTICE makes me think you have been given some training materials. You may need to read the introduction or instructions on how to import the files so that they are available for use in SAS.

View solution in original post

8 REPLIES 8
ballardw
Super User

How did you place the data set SASPRACTICE into the folder c:\users\desktop?

ajith
Calcite | Level 5

i placed the saspractice file inside the Myfolder folder

Reeza
Super User

If your using SAS UE make sure to place the file in the myfolders folder you created during set up. 

Then refer to it using the Unix notation. 

 

/folded/myfolders/file_name.csv

 

 

If you continue to get errors please post the code and log. 

ajith
Calcite | Level 5

Hi Reeza

 

it still doesnt work.. i changed the file format to csv from the xlsx originally.

also,  i put the name of the file at the end of the path...still the error message says error: file FOL.PR.data does not exist

 

thanks

ap

Reeza
Super User

@ajith wrote:

Hi Reeza

 

it still doesnt work.. i changed the file format to csv from the xlsx originally.

also,  i put the name of the file at the end of the path...still the error message says error: file FOL.PR.data does not exist

 

thanks

ap


If you continue to get errors post the code and log. 

ballardw
Super User

Most SAS procedures use files in proprietary SAS file formats. If you data is in a text, csv, xls, xlsx or other file format then the data has to be imported into SAS so the values are in the right file format. Until you have done that using either a wizard, task or code written to read the data there is not a SAS formatted data set and so the "the data set does not exist".

 

The name SASPRACTICE makes me think you have been given some training materials. You may need to read the introduction or instructions on how to import the files so that they are available for use in SAS.

ajith
Calcite | Level 5

agree. this is the problem. i stored it as an xlsx and csv file. i will change it to a sas data set. hopefully that will solve the problem

ballardw
Super User

Do you do a file save as or just change the extension? If that is what you did then change the extension back to sas7bdat.

If it is a program file then there's likely more work to go

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

Creating Custom Steps in SAS Studio

Check out this tutorial series to learn how to build your own steps in SAS Studio.

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
  • 8 replies
  • 2940 views
  • 0 likes
  • 3 in conversation