Learning SAS? Welcome to the exclusive online community for all SAS learners.

infile statement problem

Accepted Solution Solved
Reply
New Contributor
Posts: 4
Accepted Solution

infile statement problem

HI,

I can't get the infile statement to work in the University edition.  I get the error that the physical file does not exist, but it really does.

Any help would be appreciated.

 

The Libname test '/folders/myfolders'; was successfully executed too.

 

Thanks very much.

DavidL75

 

1 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;
55
56 DATA cars;
57 infile 'folders/myfolders/cardata.txt';
58 INPUT mpg weight price;
59 RUN;
 
ERROR: Physical file does not exist, /opt/sasinside/SASConfig/Lev1/SASApp/folders/myfolders/cardata.txt.
NOTE: The SAS System stopped processing this step because of errors.
WARNING: The data set WORK.CARS may be incomplete. When this step was stopped there were 0 observations and 3 variables.
WARNING: Data set WORK.CARS was not replaced because this step was stopped.

Accepted Solutions
Solution
‎04-25-2016 11:43 AM
New Contributor
Posts: 4

Re: infile statement problem 4/20

Oh Dear,

Again, I have the following error when using the infile statement:

56 DATA cars;
57 infile "/folders/myfolders/cardata.txt";
58 INPUT mpg weight price;
59 RUN;
 
ERROR: Physical file does not exist, /folders/myfolders/cardata.txt.
NOTE: The SAS System stopped processing this step because of errors.
WARNING: The data set WORK.CARS may be incomplete. When this step was stopped there were 0 observations and 3 variables.
WARNING: Data set WORK.CARS was not replaced because this step was stopped.
 
Maybe I sould re-install the SAS vApp.
 
Thanks again,
 
DavidL75

View solution in original post


All Replies
Super User
Posts: 19,789

Re: infile statement problem

You're missing the first / before folders. You have it in libname but not file path. 

Solution
‎04-25-2016 11:43 AM
New Contributor
Posts: 4

Re: infile statement problem 4/20

Oh Dear,

Again, I have the following error when using the infile statement:

56 DATA cars;
57 infile "/folders/myfolders/cardata.txt";
58 INPUT mpg weight price;
59 RUN;
 
ERROR: Physical file does not exist, /folders/myfolders/cardata.txt.
NOTE: The SAS System stopped processing this step because of errors.
WARNING: The data set WORK.CARS may be incomplete. When this step was stopped there were 0 observations and 3 variables.
WARNING: Data set WORK.CARS was not replaced because this step was stopped.
 
Maybe I sould re-install the SAS vApp.
 
Thanks again,
 
DavidL75
Super User
Posts: 19,789

Re: infile statement problem 4/20

If the libname works this should m

 

make sure you match the case, UNIX is case sensitive. 

 

Can you post a screen shot of your myfolders?

New Contributor
Posts: 4

Re: infile statement problem 4/20

Reeza,

I seem to have cured my infile problem.  I went back to virtual box and edited my shared folder.  That did it!  I successfully ran a few of my SAS programs that had the infile statement in them.

Thanks for your help and for getting back to me.

DavidL75

 

☑ This topic is solved.

Need further help from the community? Please ask a new question.

Discussion stats
  • 4 replies
  • 422 views
  • 3 likes
  • 2 in conversation