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 / rohan
select empno from emp where (sal,deptno) in ( select max
(sal),deptno from emp where deptno in (10,20) group by
deptno)
| Is This Answer Correct ? | 13 Yes | 6 No |
Post New Answer View All Answers
What is sql and how does it work?
Why do we use sql constraints? Which constraints we can use while creating database in sql?
How do you remove duplicate records from a table?
What is a string data type in sql?
What is pl sql code?
what is 'mysqladmin' in mysql? : Sql dba
What is the main difference between sql and pl/sql?
What is sql performance tuning?
What are stored procedures used for?
What is the process of debugging?
What is rtm in testing?
what is 'trigger' in sql? : Sql dba
Is sql scripting language?
how do you login to mysql using unix shell? : Sql dba
What is difference between sql function and stored procedure?