How would you delete observations with duplicate keys?
Answers were Sorted based on User's Feedback
Answer / ganesh
use nodupkey in proc sort automatically the duplicate key
going to delete.
| Is This Answer Correct ? | 2 Yes | 0 No |
Answer / ganesh
we can delete the observation by using NODUP.
proc sort data=name nodup;
by varname;
run;
| Is This Answer Correct ? | 2 Yes | 0 No |
Answer / haritha
In data step first dot variable and last dot variable use
to delete the duplicate values.
by using no dup we delete the duplicate values in row wise
and no dup key is used to delete the duplicate values in
column wise it means observation
and distinct is use to delete the duplicate values in proc
sql
| Is This Answer Correct ? | 3 Yes | 1 No |
Answer / chirag patel
using Nodup you can delete duplicate observation
| Is This Answer Correct ? | 4 Yes | 3 No |
Answer / roopanwita
There is stage called Remove Duplicate to delete duplicate
record and also Sort stage do same funtion.Otherwise if
source databse is a table,then in source SQL we can select
distinct value.
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / thirumalesh
NoDupKey is to delete duplicate observations based on by variables as a key variable, Noduprecs is to delete multiple observations with same values(repeated values).
also it can be done using proc sql,
and using fist and last statements in if condiotion.
| Is This Answer Correct ? | 1 Yes | 0 No |
If you’re not wanting any SAS output from a data step, how would you code the data statement to prevent SAS from producing a set?
how to extract data from SAP servers? Is like oracle servers or any other methods to extract please reply me.
how to write code for left outer join in SAs using datastep?
Have you ever linked SAS code, If so, describe the link and any required statements used to either process the code or the step itself?
What is the order of evaluation of the following operators + - * / ** () ???
How necessary is it to be creative in your work?
Can anyone help me about SAS Realtime scenarios in Clinical field
What is the difference between informat and format statement?
How do you add a prefix to some or all variables in a dataset using a SAS macro?
How do you specify the number of iterations and specific condition within a single do loop?
explain the function of substr in sas? : Sas-administrator
Describe how you would pass data to macro.