write a query to find 4th max salary

Answer Posted / raj

for example if we take emp table, the query like this...
select a.sal from emp a where 4=(select count(distinct(b.sal))from emp b where a.sal<=b.sal)

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is sql*plus?

773


Sql technical questions

1002


What is prepared statement in sql?

750


Show how functions and procedures are called in a pl/sql block.

766


What are the sql commands?

792






What is oracle sql developer?

788


Can cursors be part of a trigger body?

1349


What is cursor and its types?

716


Does user triggers have entry for trigger with compilation errors?

792


Is oracel sql developer written in java?

837


What's the difference between inner join and left join?

724


What is the difference between the conventional and direct path loader? : aql loader

864


What problem one might face while writing log information to a data-base table in pl/sql?

761


Is ms sql is free?

710


Write an sql query to select all records from the table?

752