BookmarkSubscribeRSS Feed
deleted_user
Not applicable
proc export needs a nonames option/statement to allow user to suppress printing of SAS dataset column names on an output file.

For example:

proc export data=mysasdata
outfile="c:\mydata.csv"
dbms=csv
replace
;
run;

Presently, there is no option or statement that will allow the user to suppress printing of the SAS data set column names as the first record of the output file.
2 REPLIES 2
deleted_user
Not applicable
> proc export needs a nonames option/statement to allow
> user to suppress printing of SAS dataset column names
> on an output file.
>
> For example:
>
> proc export data=mysasdata
> outfile="c:\mydata.csv"
> dbms=csv
> replace
> ;
> run;
>
> Presently, there is no option or statement that will
> allow the user to suppress printing of the SAS data
> set column names as the first record of the output
> file.

for a short (5-line) work around (while you wait and hope ? )

data _null_ ;
file "output file path&name -quoted" dsd lrecl= 30000 ;
set your.dataset ;
put ( _all_ )( : ) ;
run ;

it seems short enough not to need wrappng in a macro !

Good Luck

PeterC
Chiefsfan4ever
Calcite | Level 5
Just to add to Peter's comments, you would want a dsd statement to make it comma delimited


Data _null_;
file &outfile. DSD DLM = ',';
Set your.dataset;
put (_all_)(:);
run;

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

SAS Enterprise Guide vs. SAS Studio

What’s the difference between SAS Enterprise Guide and SAS Studio? How are they similar? Just ask SAS’ Danny Modlin.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 850 views
  • 0 likes
  • 2 in conversation