When merging 2 datasets with a common variable (not merge
key), how to keep both?
Answers were Sorted based on User's Feedback
Answer / reshma
data newdata;
merge dataset1 (in=a) datset2 (in=b);
if a or b;
by commonvar;
run;
| Is This Answer Correct ? | 7 Yes | 2 No |
Answer / vigneshwaran.s
Rename the variable in First data or in The Second Data:
Like,
Merge A(rename=(comman_var=New_var))(in=x)
B (in=y);
by New_var;
Run;
| Is This Answer Correct ? | 4 Yes | 0 No |
Answer / madhavi.nowduru@gmail.com
set dataset1 dataset2;
by var;
| Is This Answer Correct ? | 0 Yes | 3 No |
what is study design in while working with SAS? what are screening variables in SAS?
What are pdv and it functions?
Explain append procedure?
please can you tell me that in companies sas work are doing by through sas coding or sas wizard ??
what are 5 ways to perform a table lookup in sas? : Sas-administrator
How do you add a number to a macro variable?
I am having a stored process.it needs to route my report to both hthml and Xls.By default SP routes to html.I used the PRINTTO to route the html to Xls.BUt it createsthe file not but no content was written to file(0KB)?how can i do it?
What is a post baseline?
What are the data types that sas contain?
In which format does Date stores in sas..? What is the use of DATE in SAS.?
Which function is used to count the number of intervals between two sas dates?
What is a macro routine?