This post was kindly contributed by StudySAS Blog - go there to comment and to read the full post. |
SAS places the variables names in Row 1 when you try to
create an excel or .CSV file of the SAS
dataset. I have found a tip to tell SAS not to keep variable names in
the row 1 of .CSV file.
SAScommunity.org page has put together nice information
regarding how to do this.
1 Run PROC EXPORT with
PUTNAMES=NO
2 Run PROC EXPORT and recall
and edit the code
3 Run PROC EXPORT and use a
DATA step to rewrite the file without the first row
4 DATA _NULL_ with a PUT
statement
5 DATA _NULL_ with a PUT
statement, all fields quoted
6 ODS CSV and PROC REPORT
with suppressed column headers
7 The %ds2csv SAS
Institute utility macro
8 The CSV tagset and the
table_headers=”NO” option
Run
PROC EXPORT with PUTNAMES=NO
Sample program
proc
export data=data_to_export outfile=’C:\data_exported.csv’
dbms=csv
…
[[ This is a content summary only. Visit my website for full links, other content, and more! ]]
This post was kindly contributed by StudySAS Blog - go there to comment and to read the full post. |