How would you code a merge that will write the matches of
both to one data set, the non-matches from the left-most
data set to a second data set, and the non-matches of the
right-most data set to a third data set?
Answer Posted / reddy
data both left_only right_only;
merge dataset1(in=a) dataset2(in=b);
by variable;
if a and b then output both;
if a and not b then output left_only;
if b and not a then output right_only;
run;
i think these is the easy way of writing the code,if any
one nows other please specify.thanks!
Is This Answer Correct ? | 11 Yes | 4 No |
Post New Answer View All Answers
Will it bother you if the guy at the next desk times the frequency and duration of your bathroom or coffee breaks on the grounds that ?you are getting paid twice as much as he is??
how to generate the test data in sas without input data? : Sas-administrator
What is the order of application for output data set options, input data set options and SAS statements?
what is the primary data source for the wrs? : Sas-bi
Give some examples where proc report’s defaults are same as proc print’s defaults?
Differentiate input and infile.
how to create the AE dataset by using SDTMIG specifications and SAP plan by using UNIX platform?
if a variable contain dates like "2015/01"---"2015/12" (yymm) ,How to add day to those dates,if them month is jan then 31 if the month is feb then 28 so on ...
Name validation tools used in SAS
Do we follow ADAM in analysis dataset development?How? Usually which version? Why is it necessary?
I have 3 years of work experience at a startup and recently got certified in Data Science with SAS. I need to know how to get into the analytics industry
What are the functions used for character handling?
Why double trailing @@ is used in input statement?
what other sas products have you used and consider yourself proficient in using? : Sas programming
What do you understand by the term Normal Distribution?