BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Hi,
I'm trying to Import an excel file process it and export to the same file. When I try doing this I get this following error. Can SAS handle this?


WARNING: File _IMEX_.'Sheet1$$'n.DATA does not exist.
WARNING: Table _IMEX_."Sheet1$$" has not been dropped.
ERROR: The MS Excel table Sheet1$ has been opened for OUTPUT. This table already exists, or there is
a name conflict with an existing object. This table will not be replaced. This engine does not
support the REPLACE option.
ERROR: Export unsuccessful. See SAS Log for details.

My code:
PROC IMPORT OUT= WORK.EXTRACTMASTER
DATAFILE= "V:\LifeMaster\2009-05TestNS\RawData\ExtractMaster.xls"
DBMS=EXCEL REPLACE;
SHEET="Sheet1$";
GETNAMES=YES;
MIXED=NO;
SCANTEXT=YES;
USEDATE=YES;
SCANTIME=YES;
RUN;

Proc export data = work.updated_excel
outfile = "V:\LifeMaster\2009-05TestNS\RawData\ExtractMaster.xls"
dbms = excel
replace;
SHEET="Sheet1$";
run;
1 REPLY 1
ChrisNZ
Tourmaline | Level 20
Try using a stylesheet name without the $ sign to export.
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
  • 1 reply
  • 1651 views
  • 0 likes
  • 2 in conversation