you have a data set like this.
data qqq;
input name $ total;
cards;
qq 22
ww 33
qq 22
ee 44
rr 33
ww 44
;
run;
and you want output like this.........
name total
qq 22
ww 44
Do it by data set step.
Answer Posted / singh.naveen409
proc sort data=qqq;
by name;
run;
options mlogic;
data www;
set qqq;
by name;
if first.name then serial=1
run;
data wwq (drop=serial);
set www;
if serial ne '1';
run;
Is This Answer Correct ? | 0 Yes | 5 No |
Post New Answer View All Answers
Differentiate between sas functions and sas procedures.
What is the length assigned to the target variable by the scan function?
Explain what is data step?
AE datasets names? how many types?
what is ae onset date n what is RDS
What do the sas log messages “numeric values have been converted to character” mean? What are the implications?
Explain the use of proc print and proc contents?
Explain the difference between using drop = data set option in set and data statement?
How we can create SAS USER DEFINED CODE?
What are the functions used for character handling?
what do the sas log messages "numeric values have been converted to character" mean? : Sas programming
in the flow of data step processing, what is the first action in a typical data step? : Sas programming
How will you use the WHO Drug Dictionary for Reporting Clinical Trials?
What system options would you use to help debug a macro? : sas-macro
How do you convert basic cube to transaction cube and transaction cube to basic cube?