how to get second highest salary from a employee table and
how get a 5th highest salary from a employee table?
Answer Posted / pricil kurian
/*sort employee table by salary in desending order */
proc sort data=xx nodupkey;
by descending sal ;
run;
/*outputting the second and 5th largest salary to then yy
dataset */
data yy;
set xx;
if _n_ in (2, 5) then output;
run;
| Is This Answer Correct ? | 35 Yes | 13 No |
Post New Answer View All Answers
What are the functions which are used for character handling functions?
Explain append procedure?
Differences between where and if statement?
What is the difference between nodupkey and nodup options?
how are numeric and character missing values represented internally? : Sas programming
What is the difference between %local and %global? : sas-macro
what is treatment emergent events and treatment emregent adverse event
Hi Friends, Am Priya,new to your forum. am looking for Interview questions on SAS Platform Administration. I searched everywhere but I couldn't find them,please can anyone help me with complete interview questions normally everyone will face in the interviews on SAS Administration. am really facing problems in the interviews,am not able to answer any of their questions. I would really appreciate all your help if you can email the complete Interview Questions to priyafeb84@gmail.com Kindly awaiting for your reply with eager
What is the different between functions and PROCs that calculate the same simple descriptive statistics?
what are _numeric_ and _character_ and what do they do? : Sas programming
Explain translate function?
what is the effect of the options statement errors=1? : Sas programming
What is a pdv and what are its functions?
i want for interview question & answer plz it need immediate send t my mail raviprakashmot@gmal.cm
If you were told to create many records from one record, show how you would do this using array and with proc transpose?