BookmarkSubscribeRSS Feed
Pavan_SAS
SAS Employee
why i am getting below error?

code:
PROC IMPORT OUT= WORK.QWE
DATAFILE= "D:\Documents and Settings\pavan.kumarjupelli\Desktop\AC_Tracker_June09.xls"
DBMS=EXCEL2000 REPLACE;
SHEET="'AC Production_Pavan$'";
RANGE="A2:AP100";
GETNAMES=YES;
RUN;

error:
ERROR: Describe error: The Microsoft Jet database engine could not find the object
''AC Production_Pavan$'$A2:AP100'. Make sure the object exists and that you spell its name and the
path name correctly.
ERROR: Import unsuccessful. See SAS Log for details.
NOTE: The SAS System stopped processing this step because of errors.
NOTE: PROCEDURE IMPORT used:
real time 0.79 seconds
cpu time 0.11 seconds

i am trying to import one excel sheet in which var names are in 2nd row and data is starting from 3rd row. i am using sas 8.2.
4 REPLIES 4
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
It would be most helpful for you to share the expanded SAS log output revealing more about the SAS processing, much as the SAS diagnostic message states, "See SAS Log for details."

Post a reply with the relevant SAS-generated DATA step processing and I expect there will be some particular diagnostic information there -- also you may want to investigate the XLS document as well for possible issues.

Scott Barry
SBBWorks, Inc.
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
First - check the syntax and exact content of your entire SHEET= keyword, more specifically the surrounding quote and double-quote characters specified (and revealed in the SAS log diagnostic message.

Scott Barry
SBBWorks, Inc.
Pavan_SAS
SAS Employee
what i have observed is:

if i have removed the space(between AC and Production) and single quotes which are inside double quotes from sheet name " 'AC Production_Pavan$' ",
means if i will keep as "ACProduction_Pavan$", i am getting the result without any errors.

here i understud that becas of spaces with in the sheet name, they have kept single quotes within double quotes. If i will remove single quotes without removing the space, also i am getting wrong result.

so, now our issues is that how i can read sheet name which contains spaces?
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
Have a look at the DOC - both SHEET= and RANGE= parameters can be enclosed in double-quotes. Also there is some mention about coding the trailing "$" for the sheet, which you may want to also review for relevance.

Scott Barry
SBBWorks, Inc.

SAS Support website http://support.sas.com/ - the 9.2 doc here should be relevant to your interests, I would say:

SAS/ACCESS(R) 9.2 Interface to PC Files: Reference
Microsoft Excel Workbook Files
Microsoft Excel Files Essentials
http://support.sas.com/documentation/cdl/en/acpcref/61891/HTML/default/a003103761.htm

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

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