I am using proce export to export the SAS data to excel file. but i need to have two headers(top one is lable with spaces). is there any simple solution? my data has preceeesing zero numbers as customer ID.
basically i want to have the same format of dates, numbers, characters and numbers with preceeding zeros. but with extra header.
CUSTOMER NUMBER
CUSTNBR
00001213
00001212
00121544
Thanks,
Alankar
Hi Alankar,
Could you please provide some sample of your current data and the expected output data?
regards,
Tushar J.
Hi,
Is the above your final report? Just CUSTOMER_NUMBER???? PROC REPORT will do this very easily (give you two headers), but PROC EXPORT will not. Also, there is a possibility that Excel will ignore the SAS formats when it opens your exported workbook. That's because Excel has its own defaults for column formats, widths, etc and PROC EXPORT does not have many ways to influence how Excel opens the file.
On the other hand, if you use ODS, you can influence how Excel treats your data because you can send Microsoft-specific formats to Excel, as described in this paper: http://support.sas.com/resources/papers/proceedings11/266-2011.pdf (leading zeroes treatment is one of the examples).
cynthia
Sorry for insufficient explanation.
I need to export 3 sheets, each with 20 variables. I have dates, char variables, numbers and preceding zero variables, like ID and account numbers.
SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!
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.
Ready to level-up your skills? Choose your own adventure.