create macros---you have 365 number of data and you need to
merge it throw the macros,,,,,,
data file1;
input a @@;
cards;
1 2 3 4
;
run;
data file2;
input a @@;
cards;
5 6 7 8
;
run;
data file3;
input a @@;
cards;
9 10 11 12
;
run;data file4;
input a @@;
cards;
13 14 15 16
;
run;
Answer Posted / venkat
%macro merging(f,x);
%do i=1 %to %eval(&x-1);
data &f&n;
merge &f&n &f%eval(&i+1);
by a;
run;
%end;
%mend merging;
%merging(file,4);
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
what is ae onset date n what is RDS
State the difference between INFORMAT and FORMAT ?
List down the reasons for choosing sas over other data analytics tools.
Difference between sum function and using “+” operator?
Mention common programming errors committed in sas ?
What would you change about your job?
What are the statements in proc sql?
how sas deals with business intelligence? : Sas-bi
what is a method for assigning first.var and last.var to the by groupvariable on unsorted data? : Sas programming
what techniques and/or procs do you use for tables? : Sas programming
How do you connect the desktop application to metadata server? : sas-grid-administration
Name validation tools used in SAS
What’s the difference between var b1 – b3 and var b1 — b3?
If you could design your ideal job, what would it look like?
What are the new features included in the new version of SAS Programming Language?