Return to Snippet

Revision: 53171
at November 15, 2011 14:20 by webonomic


Initial Code
libname BC "C:\file\path";

%macro filecreate;
    %do x=1 %to 700;
    filename lb18 "C:\folder\lb&x..txt" LRECL=8006;
    data _null_;
          set BC.some_data (firstobs=&x obs=&x);
          file lb18 dsd dlm='09'x;
          put var1;
    run;
    %end;
%mend;

%filecreate;

Initial URL
http://jaredprins.com/sas/2011/11/14/convert-sas-dataset-to-text-file.html

Initial Description
This SAS macro will convert a dataset to a text file

Initial Title
Convert SAS dataset to Text file

Initial Tags
text, convert

Initial Language
SAS