How to find the second largest salary in the emp database and
also How to find 3rd,4th and so on ........ in the emp database
plz mail the answer @ mak2786@gmail.com
Answer Posted / veerdhawal
mysql> select max(sal) from emp where sal not in (select
max(sal) from emp);
+----------+
| max(sal) |
+----------+
| 30000 |
+----------+
1 row in set (0.01 sec)
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
Do you know what is a linked server in sql server?
What happens if null values are involved in comparison operations?
How many types of subqueries are there in sql server?
When should you use an instead of trigger?
List some major differences between triggers and stored procedures?
how do you implement one-to-one, one-to-many and many-to-many relationships while designing tables? : Sql server database administration
Can you leave a union at any time?
What is primary key, unique key, and foreign key?
How to recreate an existing index in ms sql server?
You accidentally delete the msdb database what effect does this have on your existing sql databases, and how do you recover?
What is scd (slowly changing dimension)? : sql server analysis services, ssas
mention different types of relationships in the dbms?
What is bit data type? What's the information that can be stored inside a bit column?
How to assign new column names in a view?
What is bulkcopy in sql?