How to select the name of employee who is getting maximum
sal with out using subquery

Answers were Sorted based on User's Feedback



How to select the name of employee who is getting maximum sal with out using subquery..

Answer / girija.112

ANS :
select max(ename) keep (dense_rank last order by sal) ename
from emp

ENAME
-----
KING

Is This Answer Correct ?    8 Yes 4 No

How to select the name of employee who is getting maximum sal with out using subquery..

Answer / srinu.g

select b.ename from emp b,(select max(sal) k from emp) a
where a.k=b.sal;

Is This Answer Correct ?    2 Yes 0 No

How to select the name of employee who is getting maximum sal with out using subquery..

Answer / naidu

SELECT * FROM Emp
WHERE LEVEL=&Number
CONNECT BY PRIOR Sal > Sal ;

Is This Answer Correct ?    0 Yes 0 No

How to select the name of employee who is getting maximum sal with out using subquery..

Answer / naresh

Here is the solution.

Select E_id, E_name,Salary from the Employes group by E_ID
Having Salary=Max(Salary)

Should work.
Try it and let me know.

Cheers!
Naresh

Is This Answer Correct ?    0 Yes 0 No

How to select the name of employee who is getting maximum sal with out using subquery..

Answer / niladri chatterjee

Select * From (Select * From Employee Order By Salary Desc) a
Where rownum=1 ;

Or

Select * From (Select Emp_id, Emp_NM, Salary From Employee Order By Salary Desc) a
Where rownum=1 ;

Based on Oracle 11g.

Is This Answer Correct ?    0 Yes 0 No

How to select the name of employee who is getting maximum sal with out using subquery..

Answer / flitchner

select name from (select max(sal) as salary from emp) a,
emp b
where a.salary = b.sal;

Is This Answer Correct ?    0 Yes 1 No

How to select the name of employee who is getting maximum sal with out using subquery..

Answer / neha

select a.ename from (select ename from emp ORDER BY SAL
desc,ROWNUM DESC)a
where rownum=1;

Is This Answer Correct ?    0 Yes 1 No

How to select the name of employee who is getting maximum sal with out using subquery..

Answer / lince

select top 1 Name from emp order by sal desc

Is This Answer Correct ?    8 Yes 11 No

How to select the name of employee who is getting maximum sal with out using subquery..

Answer / atal patra

select ename,max(sal)from emp group by ename;

Is This Answer Correct ?    6 Yes 9 No

How to select the name of employee who is getting maximum sal with out using subquery..

Answer / pavan

select * from (select ename from emp order by rownuum desc)
where rownum=1;

Is This Answer Correct ?    0 Yes 3 No

Post New Answer

More Oracle General Interview Questions

What are the ways tablespaces can be managed and how do they differ?

0 Answers  


What privilege is needed for a user to insert rows to tables in another schema?

0 Answers  


Where do we use decode and case statements?

0 Answers  


What are the components of Logical database structure of ORACLE database?

4 Answers  


How to delete a user account in oracle?

0 Answers  


What is the function of Optimizer ?

1 Answers  


How to convert times to characters in oracle?

0 Answers  


How do I use os authentication with weblogic jdriver for oracle and connection pools?

0 Answers  


Can multiple cursors being opened at the same time?

0 Answers  


what is the difference between no rows returned and null returned?

2 Answers  


How can we find out the current date and time in oracle?

0 Answers  


What is an oracle database table?

0 Answers  


Categories
  • Oracle General Interview Questions Oracle General (1808)
  • Oracle DBA (Database Administration) Interview Questions Oracle DBA (Database Administration) (261)
  • Oracle Call Interface (OCI) Interview Questions Oracle Call Interface (OCI) (10)
  • Oracle Architecture Interview Questions Oracle Architecture (90)
  • Oracle Security Interview Questions Oracle Security (38)
  • Oracle Forms Reports Interview Questions Oracle Forms Reports (510)
  • Oracle Data Integrator (ODI) Interview Questions Oracle Data Integrator (ODI) (120)
  • Oracle ETL Interview Questions Oracle ETL (15)
  • Oracle RAC Interview Questions Oracle RAC (93)
  • Oracle D2K Interview Questions Oracle D2K (72)
  • Oracle AllOther Interview Questions Oracle AllOther (241)