how to find the second highest salary from emp table?
Answer Posted / hari chaudhary
All My friend use this query then good result of your sql
database find in second or Third last data find.....
Select distinct(salary) From employee E1 Where
(n-1) = (Select Count(Distinct(E2.salary)) From employee E2
Where E2.salary > E1.salary)
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is left join in postgresql?
How many aggregate functions are available there in sql?
Which join condition can be specified using on clause?
Does pl sql work in mysql?
How do I clear the screen in sql plus?
what are the differences between char and varchar? : Sql dba
what are ddl statements in mysql? : Sql dba
Which is better join or inner query?
how can you create an empty table from an existing table? : Sql dba
What are tables in sql?
What is the use of function "module procedure" in pl/sql?
What does dml mean?
Differentiate pl/sql and sql?
Can we use joins in subquery?
What are the types of sql commands?