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

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

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.

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