BookmarkSubscribeRSS Feed
khalillx
Fluorite | Level 6

I used this command which I always do to import my data:

PROC IMPORT OUT = WORK.one;
DATAFILE= "C:\Users\laura\OneDrive\Documents\econ485\project1data.csv";
DBMS=csv REPLACE;
RUN;

 

But I'm getting this error message: PROC IMPORT OUT = WORK.one;
ERROR: FILE= or TABLE= is required and must be specified.

 

But I have specified my file so I'm not sure why I'm getting this error message. I successfully created a libname with my pathway so I know my pathway is fine.

7 REPLIES 7
VDD
Ammonite | Level 13 VDD
Ammonite | Level 13

try this

PROC IMPORT DATAFILE= "C:\Users\laura\OneDrive\Documents\econ485\project1data.csv" OUT = WORK.one;
DBMS=csv REPLACE;
RUN;
khalillx
Fluorite | Level 6

libname session1 "C:\Users\laura\OneDrive\Documents\econ485";

 

PROC IMPORT OUT= SESSION1;
DATAFILE= "C:\Users\laura\OneDrive\Documents\econ485\project1data.csv";
DBMS=csv REPLACE;
RUN;

 

ERROR: FILE= or TABLE= is required and must be specified.
NOTE: The SAS System stopped processing this step because of errors.
NOTE: PROCEDURE IMPORT used (Total process time):
real time 0.00 seconds
cpu time 0.01 seconds

 

What does this mean? I've used this command so many times and never had this issue. Please help. 

VDD
Ammonite | Level 13 VDD
Ammonite | Level 13

writing the code in the expected order would help

please look at this link

http://support.sas.com/documentation/cdl/en/proc/61895/HTML/default/viewer.htm#a000314361.htm

 

 

PROC IMPORT 
DATAFILE= "C:\Users\laura\OneDrive\Documents\econ485\project1data.csv"
OUT= SESSION1
DBMS=csv 
REPLACE;
RUN;

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 7 replies
  • 2533 views
  • 2 likes
  • 3 in conversation