i want department wise maxmum salary and empolyee name
Answer Posted / sanjay pradhan
select ename,sal,deptno from emp where (deptno,sal) in
(select deptno,max(sal) from emp group by deptno);
| Is This Answer Correct ? | 15 Yes | 4 No |
Post New Answer View All Answers
How to update values in a table in oracle?
HI ALL, CAN ANYONE TELL ME THE DIFFERENCES BETWEEN SQL CLUSTURS,MSQL CLUSTERS,ORACLE CLUSTERS.......THANKS IN ADVANCE
What happens if the update subquery returns multiple rows?
How many objectname will be created for a single table drop function? Why 'flashback' query giving error "ORA-38312: original name is used by an existing object" while getting the table?
What is the scope of a local variable?
HI Friends Myself Manoj,i am from bengaluru.i have 1 yr of exp in PLSQL but not upto the mark..now attending interviews but m not able to clear even 1 round..i have attended 3 interviews till today.purpose of writing this query is,i want to know the intreview topics that interviewer going to ask frequently,mainly SCENARIO based questions.IF anybody have any PLSQL projects please give it to me,it will helps me alot.Thanks for your patience.
What is the purpose of tables, private synonyms and public synonyms in Oracle?
What is oracle rownum?
Provide an example of a shell script which logs into SQLPLUS as SYS, determines the current date, changes the date format to include minutes & seconds, issues a drop table command, displays the date again, and finally exits.
How to create id with auto_increment on oracle?
How to connect to oracle using service name instead of sid?
What is a partition in oracle?
Difference between inner join vs where ?
How can I combine multiple rows into a comma-delimited list in oracle?
Explain the difference between replace() and translate() functions in oracle?