BookmarkSubscribeRSS Feed
srinivasa_attot
Fluorite | Level 6
Thank you for testing the xls issue at your end.
SAS 9.4 M8 is installed on Linux
I am opening in windows 11 Enterprise.
My excel version is "Microsoft Excel for Microsoft 365 MSO(Version 2604 Build 16........) 64 bit.

I will share data shortly.
Tom
Super User Tom
Super User

I have no trouble making an XLS file on SAS On Demand and then downloading the file to my personal computer and opening it with the Numbers application on MacOS.

 73         %put &=sysvlong;
 SYSVLONG=9.04.01M8P022223
 74         filename xls '~/example.xls';
 75         proc export data=sashelp.class dbms=xls file=xls replace;
 76         run;
 
 NOTE: The export data set has 19 observations and 5 variables.
 NOTE: "XLS" file was successfully created.
 NOTE: PROCEDURE EXPORT used (Total process time):
       real time           0.30 seconds
       cpu time            0.06 seconds

And it does not matter if the file already exists. The existing file is overwritten with a new good XLS file.

 73         %put &=sysvlong;
 SYSVLONG=9.04.01M8P022223
 74         filename xls '~/example.xls';
 75         data _null_;
 76           file xls;
 77           put 'garbage';
 78         run;
 
 NOTE: The file XLS is:
       Filename=/home/tom.abernathy/example.xls,
       Owner Name=tom.abernathy,Group Name=oda,
       Access Permission=-rw-r--r--,
       Last Modified=10Jun2026:11:29:46
 
 NOTE: 1 record was written to the file XLS.
       The minimum record length was 7.
       The maximum record length was 7.
 NOTE: DATA statement used (Total process time):
       real time           0.88 seconds
       cpu time            0.05 seconds
       
 
 79         proc export data=sashelp.class dbms=xls file=xls replace;
 80         run;
 
 NOTE: The export data set has 19 observations and 5 variables.
 NOTE: "XLS" file was successfully created.
 NOTE: PROCEDURE EXPORT used (Total process time):
       real time           0.68 seconds
       cpu time            0.08 seconds
       
 

Perhaps you are trying to write to a file that is already open in another application?

Perhaps you downloaded the wrong file?

Perhaps you have something wrong in your SAS installation? Open a ticket with SAS support.

srinivasa_attot
Fluorite | Level 6
Thanks Tom.. I will open a case with SAS tech support

Catch up on SAS Innovate 2026

Nearly 200 sessions are now available on demand in the Innovate Hub.

Watch Now →
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
  • 17 replies
  • 677 views
  • 0 likes
  • 7 in conversation