BookmarkSubscribeRSS Feed
Nikhil_1393
Calcite | Level 5

DATA MYDATA;
INFILE 'E:\SASUniversityEdition\myfolders\Essentials\EXAMPLE.CSV' DLM=',' FIRSTOBS=2 OBS=11;
INPUT GROUP $ AGE TIME1 TIME2 TIME3 Time4 SOCIO;
PROC PRINT DATA=MYDATA;
RUN;

 

 

After running this my SAS is showing that the physical file does not exist, Although the file is there at the specified location in INFILE statement.Can anybody help me with this.....!

4 REPLIES 4
Shmuel
Garnet | Level 18

TRY

INFILE 'myfolders\Essentials\EXAMPLE.CSV' DLM=',' FIRSTOBS=2 OBS=11;
Nikhil_1393
Calcite | Level 5

It still is not working......!

JChambo
Fluorite | Level 6

Do you connect to a server to run sas programs? It looks like you might, and if that is the case then the file path needs to be correct from the perspective of the server, not your own computer.

 

You would need to copy the input file from your computer to a shared drive or to the server itself. If you access a shared drive through a drive letter (eg. S:\ drive) then the server would need to have the exact same drive letter setup. If the server does not, you'll need to get the UNC path to the shared drive.

 

 

Kurt_Bremser
Super User

It looks like you are using University Edition. In this case, the filename should be

infile '/folders/myfolder/Essentials/EXAMPLE.CSV' dlm=',' firstobs=2 obs=11;

Note that the underlying Linux of UE is case sensitive where filenames are concerned, so upper/lowercase needs to match exactly.

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
  • 4 replies
  • 732 views
  • 0 likes
  • 4 in conversation