write a query for the fifth highest salary?
Answers were Sorted based on User's Feedback
Answer / arshi
SELECT MAX(Salary) AS Expr1
FROM TableName
WHERE (Salary NOT IN
(SELECT TOP (4) MAX(Salary)
AS Expr1
FROM TableName AS
TableName_1
GROUP BY Salary
ORDER BY SalaryDESC))
| Is This Answer Correct ? | 6 Yes | 7 No |
Answer / ramesh
select top 1 salary
(select distinct top 5
salary from employees
order by salary desc)
a order by salary
| Is This Answer Correct ? | 6 Yes | 9 No |
Answer / sujit
Hop it helps!
Select sal from (select sal from emp order by sal desc
where rownum<6);
| Is This Answer Correct ? | 0 Yes | 3 No |
Answer / payal
select salary from emp order by salary desc limit 4,1
| Is This Answer Correct ? | 3 Yes | 10 No |
Answer / aravind
select * from (select sal from emp order by desc) emp where
rownum = 5
| Is This Answer Correct ? | 6 Yes | 14 No |
Answer / p.chella vijaya
select top 5 (salary) from emp order by desc
| Is This Answer Correct ? | 1 Yes | 13 No |
Answer / p.chella vijaya
select top 5 (salary) from emp order by salary desc
| Is This Answer Correct ? | 1 Yes | 14 No |
What is meant by distributed system?
can i use the commands "modify" and Change in DB2 to alter my column datatype and its name in a table?
can any one tell me how i can start database testing mean what should be initial point and how i can write a query for listing page of any item thanks in advance
Define stored procedure?
Explain alternate key?
Explain database partitioning.
What is ole db source in ssis?
During insert operation in Netezza Connector, if we give direct option as Yes , is there any issue?
issues involved in modeling and building data werahouses
Is it good to store images in database?
What are the most common databases?
Explain file manager?
Oracle (3259)
SQL Server (4518)
MS Access (429)
MySQL (1402)
Postgre (483)
Sybase (267)
DB Architecture (141)
DB Administration (291)
DB Development (113)
SQL PLSQL (3330)
MongoDB (502)
IBM Informix (50)
Neo4j (82)
InfluxDB (0)
Apache CouchDB (44)
Firebird (5)
Database Management (1411)
Databases AllOther (288)