ODS Trace ON, ODS Trace OFF the trace records.
How would you code a merge that will keep only the observations that have matches from both data sets?
Using "IN" variable option.
Look at the following example.
data three;
merge one(in=x) two(in=y);
by id;
if x=1 and y=1;
run;
*or;
data three;
merge one(in=x) two(in=y);
by id;
if x and y;
run;
How would you code a merge that will keep only the observations that have matches from both data sets?
Using "IN" variable option.
Look at the following example.
data three;
merge one(in=x) two(in=y);
by id;
if x=1 and y=1;
run;
*or;
data three;
merge one(in=x) two(in=y);
by id;
if x and y;
run;
No comments:
Post a Comment