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

So I've started the case study, everything ran fine the first day with 0 errors. I come back in the following day, run the program, and I get the following error with the import statement, (below in the log). 

 

5 %_eg_hidenotesandsource; 
33 
34 proc import datafile="SASAPP:/research/econ_models/OMAP/CHAD_PRACTICE/Case Study/TSAClaims2002_2017.csv" dbms=csv 34 ! out=casestudy replace; 
35 run; 
NOTE: Unable to open parameter catalog: SASUSER.PARMS.PARMS.SLIST in update mode. Temporary parameter values will be saved to WORK.PARMS.PARMS.SLIST. ERROR: Physical file does not exist, /opt/sas94/config947/Lev1/SASApp/SASAPP:/research/econ_models/OMAP/CHAD_PRACTICE/Case Study/TSAClaims2002_2017.csv. 
ERROR: Import unsuccessful. See SAS Log for details.
 NOTE: The SAS System stopped processing this step because of errors. NOTE: PROCEDURE IMPORT used (Total process time): real time 0.04 seconds cpu time 0.05 seconds 
36 
37 %_eg_hidenotesandsource; 
51 
52 
53 %_eg_hidenotesandsource;
1 ACCEPTED SOLUTION

Accepted Solutions
ballardw
Super User

First thing is to double check where you actually stored the file.

Typically one does not place data in the SAS configuration folders such as: 

 /opt/sas94/config947/Lev1/SASApp/

as shown in the "does not exist". 

Instead of SASAPP: your path to the file should start with a drive mount point or in Windows a drive letter.

 

Second, instead of rereading raw data each session create a LIBRARY and write your data set to that library. Then you just make sure the library is available by pointing to it with a LIBNAME statement .

 

Caution with relying on proc import for files: Only 20 or so lines are examined to set variable types and properties by default. Which may make columns with mixed data numeric if the first rows are all blank or only contain digits. Later records could be set to missing because of the presence of letters or other characters. Another is that data that uses text such as "NA" "N/A" "Null" or "Missing" to denote missing numeric values will make the variable text and not numeric.

With CSV is suggest using the GUESSINGROWS = max; option. Then read the LOG for the generated data step to see the properties of the variables. If something looks odd, copy the generated data step to the editor, clean up things like line numbers and set the properties such as INFORMAT or variable name as desired and run the modified data step. Save that program for reference or future changes.

View solution in original post

1 REPLY 1
ballardw
Super User

First thing is to double check where you actually stored the file.

Typically one does not place data in the SAS configuration folders such as: 

 /opt/sas94/config947/Lev1/SASApp/

as shown in the "does not exist". 

Instead of SASAPP: your path to the file should start with a drive mount point or in Windows a drive letter.

 

Second, instead of rereading raw data each session create a LIBRARY and write your data set to that library. Then you just make sure the library is available by pointing to it with a LIBNAME statement .

 

Caution with relying on proc import for files: Only 20 or so lines are examined to set variable types and properties by default. Which may make columns with mixed data numeric if the first rows are all blank or only contain digits. Later records could be set to missing because of the presence of letters or other characters. Another is that data that uses text such as "NA" "N/A" "Null" or "Missing" to denote missing numeric values will make the variable text and not numeric.

With CSV is suggest using the GUESSINGROWS = max; option. Then read the LOG for the generated data step to see the properties of the variables. If something looks odd, copy the generated data step to the editor, clean up things like line numbers and set the properties such as INFORMAT or variable name as desired and run the modified data step. Save that program for reference or future changes.

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

Mastering the WHERE Clause in PROC SQL

SAS' Charu Shankar shares her PROC SQL expertise by showing you how to master the WHERE clause using real winter weather data.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 1 reply
  • 678 views
  • 0 likes
  • 2 in conversation