BookmarkSubscribeRSS Feed
PazM
Calcite | Level 5

Hi,

 

I seem to have a problem when i output to an Excel file from SAS 9.4. The export works fine and pastes the data into the tab i chose, however some of the data in other tabs move around to other cells. E.G Headings in column A tab 2 are arranged differently on a sheet which has no output assigned to it.

 

Not sure why this keeps happening but its abit frustrating having rewrite the row headings in again each time my export is run.

 

SAS 9.4

Excel 2010 (32 bit)

 

 

libname output pcfiles path = "......";

proc sql;
drop table output.Data;
drop table output.'Data$'n;
quit;
proc sql;
create table output.Data as
select *
from Final_Data
;quit;

libname output clear;

I have also tried a normal proc export statement and the same issue is occuring.

 

Thanks in advance

 

 

7 REPLIES 7
PazM
Calcite | Level 5

How do i find what engine i am using? 

 

Should i be using xl out xlsx = " "

Kurt_Bremser
Super User

@PazM wrote:

How do i find what engine i am using? 

 

Should i be using xl out xlsx = " "


??

 

Post the REAL version of

libname output pcfiles path = "......";

with the engine you used in the export.

PazM
Calcite | Level 5
libname output pcfiles path = "C:\Users\234783\Analysis v4.xlsx";

 

art297
Opal | Level 21

Ran into a similar problem a couple of months ago. When you open up one of the workbooks look at the upper left hand corner of the Excel screen. Does the string "[Group]" appear to the right of the Workbook name?

 

Art, CEO, AnalystFinder.com

 

PazM
Calcite | Level 5

No i can't see the "[Group]" string next to the workbook name. I'm assuming your thinking that multiple tabs are selected before the export??

art297
Opal | Level 21

Yes, that is precisely what I was thinking. Look again immediately after doing such an export where you see the odd things you described in your original question. Since ungrouping occurs as soon as someone selects a different sheet, you would only notice it immediately after creating the workbook.

 

Art, CEO, AnalystFinder.com

 

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
  • 2297 views
  • 0 likes
  • 3 in conversation