View Single Post
  #22 (permalink)  
Old 04-25-2008, 08:11 AM
Unregistered
 
Posts: n/a
Default ANY answer. Re: How to find second highest value of a column in a table?

Quote:
Originally Posted by ruby View Post
I have a table - Trade with 2 columns -Client name and quantity.
I want to find out the name of the client with second highest quantity. How do I proceed?


Ans : query is like this :

[sql]SELECT TOP 1 Salary FROM (SELECT TOP 2 Salary FROM Employee ORDER BY Salary DESC) AS E ORDER BY Salary ASC[/sql]
Reply With Quote