consider a table which contain 4 columns,ename,eno,sal and
deptno, from this table i want to know ename who having
maximum salary in deptno 10 and 20.

Answer Posted / purushotham

select ename from table where sal in
(select max(sal) from table_name
where deptno in ('10','20')
group by deptno);

Is This Answer Correct ?    16 Yes 8 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Are pl sql variables case sensitive?

602


What are some emotional triggers?

575


What is auto increment in sql?

595


Does access use sql?

570


what are the differences between procedure-oriented languages and object-oriented languages? : Sql dba

515






Mention what is the function that is used to transfer a pl/sql table log to a database table?

488


What is materialized view in sql?

469


Sql technical questions

781


What are the subsets of sql?

555


How will you distinguish a global variable with a local variable in pl/sql?

633


How do you create a unique index?

579


How to place comments in pl/sql?

613


what is column? : Sql dba

579


How do you update f as m and m as f from the below table testtable?

1105


What are joins in sql?

545