how to get second highest salary from a employee table and
how get a 5th highest salary from a employee table?
Answers were Sorted based on User's Feedback
Answer / richa
It can be done by first sorting the dataset in the
ascending order of salary and then using the 'point='
option.
For eg:
proc sort data = x;
by salary;
quit;
/*second highest salary*/
data y;
a = 2;
set x point = a;
stop;
run;
/*fifth highest salary*/
data y;
a = 5;
set x point = a;
stop;
run;
| Is This Answer Correct ? | 1 Yes | 9 No |
What is the difference between nodup and nodupkey options?
20 Answers iFlex, Makro, Talwar,
how does sas know on which server the piece of code to be executed ? say if a proc olap code is written then how the sas application would detect on which server to execute.
The Lion King is hosting an animal conference. All the animals in the world attend except one. Which animal does not attend?
What is a post baseline?
How does the internal authentication work in sas? : sas-grid-administration
what is the difference btw proc means and proc univariate?
What is a put statement?
what is the different between functions and procs that calculate the same simple descriptive statistics? : Sas programming
what is the usage for assigning error=1 in a dataset ?
what are the different ways of merging two datasets.name atleast 4.
How to get the repeated values by using sql in sas ?
How would you compile all macros from a folder in a study, within the autoexec program?