how we can find nth max salary from an employe table by
using my sql?

Answer Posted / sumit

select salary from employee e1
where (n-1)=(select count(*) from employee where
salary>e1.salary)

Is This Answer Correct ?    0 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

write a query to mysql in safe mode and to change the root password

524


How to enter numeric values as hex numbers?

536


How to show table names with 'mysqlshow'?

544


Does mysql use t sql?

578


Is mysql open source?

483






What is mysqli_select_db?

523


What port is mysql running on?

478


How do I stop a query in mysql workbench?

487


What is the use of i-am-a-dummy flag in mysql?

561


How to set the time zone for MySQL to particular country time?

2728


How many ways we can retrieve the date in result set of mysql using php?

526


how to search second maximum(second highest) salary value(integer)from table employee (field salary)in the manner so that mysql gets less load?

545


Explain about the architecture of MYSQL?

556


How would you enter characters as hex numbers?

520


What tools available for managing mysql server?

542