I have student marks in a student table. I need second
highest mark .Then what will the query for this?

Answer Posted / kumaravel

try using this...
select top 1 from student where marks in (select top 2 from
student order by marks desc)

Is This Answer Correct ?    16 Yes 10 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are data resources?

504


How to write a query with an inner join in ms sql server?

550


What are the tool windows in sql server management studio? : sql server management studio

624


How to handle error or exception in sql?

531


How does a profiler work?

515






How secure is sql server database?

525


Which is the best place or learning center for MS SQL?????In Bangladesh?????

1594


Explain different types of collation sensitivity?

533


What does the update command do?

615


How do I get Report Builder to generate a parameter that can be set by users viewing the report?

100


What are the different types of locks in the database?

488


Define primary key?

660


You have a stored procedure, which execute a lengthy batch job. This stored procedure is called from a trigger you do not want to slow the data entry process you do not want trigger to wait for this batch job to finish before it completes itself what you can do to speed up the process?

653


What is a synonym for manipulation?

550


What is bit data type?

623