can anybody tell us, how to select 2nd max salary from
table.
my id is ashish.akk@gmail.com
Answer Posted / preeti chauhan
CREATE TABLE T1(SALARY int, [NAME] varchar(50))
SELECT TOP 1 SALARY FROM (SELECT TOP 2 SALARY FROM T1 ORDER
BY SALARY DESC)T1 ORDER BY SALARY
Is This Answer Correct ? | 15 Yes | 3 No |
Post New Answer View All Answers
What is the purpose of sql profiler in sql server? : sql server database administration
Why use view instead of a table?
Can another user execute your local temporary stored procedures?
What are truncate options available in sql server? : sql server database administration
What is sql server database?
What the different components of Replication and what is their use?
What are the disadvantages of using querystrings to send data from one page to another?
How to add more data to the testing table in ms sql server?
What is provisioning, billing and metering, and connection routing concepts in the service layer?
How you provide security to cube? : sql server analysis services, ssas
What is mapping schema?
Explain how to send email from sql database?
What are the disadvantages of merge replication?
What is a field name?
What is the maximum size of a dimension? : sql server analysis services, ssas