I have a Dataset (It's the MXG ASUM70PR) that stores it's data in wide format. I want to convert it to narrow format using PROC TRANSPOSE, but the only problem is that the field names are not conducive for this routine. I set up a macro to convert the names: %macro set0(suff) ; * 123456789012345678901234567890123456 %LET LPSEQ =0123456789ABCDEFGHIJKLMNOQRSTUVWXYZ; %LET LQSEQ =123456789ABCDEFGHIJKLMNOPQ; %put start OF LP LOOP; %do j=1 %to 35; %let name = LP%substr(&LPSEQ,&j,1)&suff; %let i = %eval(&j-1); %put &suff&I = &name ; &suff&I = &name ; %end; %put start OF LQ LOOP; %do j=1 %to 26; %let Name = LQ%substr(&LQSEQ,&j,1)&suff; %let i = %eval(35+&j); %put &suff&i = &name ; &suff&i = &name ; %end; %mend; data test0 (keep = startime name0-name60); set &PDB_DAY..asum70pr; %set0(NAME); proc contents; proc print; But the field NAME0 does not appear in the resultant data set. What am I doing wrong?
... View more