How could i automate the code in the scenario:Every month
one new data set will be created for that perticular month
transaction list.Now i would like to update the data in the
source table by appending every month data automatically.
jan---set jan;
feb---set jan feb;
mar---set jan mar;
Answers were Sorted based on User's Feedback
Answer / naresh
%macro update_table(demo1)
%let X = "JAN,FEB,MAR,APR";
%do i = 1 %to 4
%let y = scan(&x,i,',');
data &Master_table;
update &Master_table &y;
by acc_id;
run
%let i = %eval(&i+1);
%end;
%mend update_table;
Is This Answer Correct ? | 1 Yes | 1 No |
Answer / satheesh
%macro sam (&mon);
data &mon1.;
set &mon.;
run;
proc append base = sav.appendData data = &mon.;
run;
%mend;
%sam(Jan);
%sam(Feb);
%sam(Mar);
Is This Answer Correct ? | 1 Yes | 1 No |
What are all the problems you faced while validating tables and reports?
0 Answers Accenture, Quintiles,
Hi... this is chandu, did MSc Microbiology, trying to get job in SAS tool, PLZ Tell me whether IT industries will give consider my education to gain a job....?
How to sort in descending order?
what is the difference between informat$8. $char8.
what is sas application server? : Sas-di
Difference between informat and format?
In this question, I rename the numeric variable phone to numphone and then try use phone=put(numphone,comma16.) to store the numeric value numphone as a string value in phone. But I get a warning tha numphone already exists and in the data sat phone doesnt exist and numphone is set to missing. Why? data names_and_more; input Name $20. Phone : comma16. Height & $10. Mixed & $8.; Name = tranwrd(Name,' ',' '); rename phone = numphone; phone = put(numphone,comma16.); datalines; Roger Cody 9,087,821,234 5ft. 10in. 50 1/8 Thomas Jefferson 3,158,488,484 6ft. 1in. 23 1/2 Marco Polo 8,001,234,567 5Ft. 6in. 40 Brian Watson 5,183,551,766 5ft. 10in 89 3/4 Michael DeMarco 4,452,322,233 6ft. 76 1/3 ;
what is the difference between proc report and proc format?
what are some problems you might encounter in processing missing values? In data steps? Arithmetic? Comparisons? Functions? Classifying data? : Sas programming
What is the difference between Regression and Logistic Regression? Can u explain the Assumptions/Conditions?
In sas admin differentiate between roles and capabilities? : sas-grid-administration
how will you location sas platform applications available from web browser? : Sas-bi