| |
GeekInterview.com > Tech FAQs > SQL
| Print | |
Question: How to get fifth maximum salary from the table with out using TOP keywork(without any keywords) in sql server 2000 Can you please guide me about this?
|
| September 09, 2006 07:40:50 |
#4 |
| Sivakumar |
Member Since: Visitor Total Comments: N/A |
RE: How to get fifth maximum salary from the table wit... |
Hi, This will solve your problem. Use "select salary from emp a where 5 = (select count(distinct(salary)) from emp b where b.salary>= a.salary) " Thanks & Regards, Sivakumar
|
| |
Back To Question | |