Find 2nd Highest salery in emp table
Select* from emp where &n=
select * count from emp where (salery >=emp.salery)
Enter n value 2
These query is correct or not. Tell me any other methods.
Answer Posted / asimananda
SELECT MAX(SAL) FROM EMP WHERE SAL < ( SELECT MAX(SAL) FROM
EMP )
Is This Answer Correct ? | 7 Yes | 2 No |
Post New Answer View All Answers
Explain important index characteristics?
What are the kinds of subquery?
What are the different types of collation sensitivity in sql server?
What structure can you implement for the database to speed up table reads?
Is it important for a database administrator to understand the operating system and file access?
What is the command used to recompile the stored procedure at run time?
What is mssql?
How does recursive cte works in sql server?
How to locate and take substrings with charindex() and substring() functions?
What do you think of this implementation? Can this be implemented better?
What are the basic functions for master, msdb, model, tempdb and resource databases?
Can we join two tables without primary key?
Explain atomicity?
Is sql server 2016 free?
Explain the use of containers in ssis and also their types?