We want to merge file A and B. File A has variable age,
file B provide birthdate. How to merge the data according
to age in file B
Answer Posted / ramesh
First calculate age in B datase
data age;
set b;
age=int(intck('day',bday,today())/365.25);
run;
sort both datasets by the age key variable and Use the
merge statement to combine the both datasets
| Is This Answer Correct ? | 10 Yes | 1 No |
Post New Answer View All Answers
what versions of sas have you used (on which platforms)? : Sas programming
What are the functions used for character handling?
What is a method for assigning first.VAR and last.VAR to the BY group variable on unsorted data?
what are sas/access and sas/connect? : Sas programming
what is change analysis in sas di ? : Sas-di
Mention sas system options to debug sas macros.
What is a method to debug and test your SAS program?
what is data access? : Sas-di
What are the different types of sas functions?
Are you involved in writing the inferential analysis plan? Tables specfications?
How would you code a macro statement to produce information on the sas log? This statement can be coded anywhere? : sas-macro
What is the use of %include statement?
What is the basic syntax of a sas program?
How would you identify a macro variable?
I have a dataset concat having variable a b & c. How to rename a b to e & f?