In a single table,How to retrieve a employee-id of an
employee who works in more than one department?
Answer Posted / millar
select employee_id,department_id from emp where employee_id in(select employee_id from emp where department_id in (select distinct
department_id from emp) group by employee_id,department_id having count(*) >1);
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
Define check constraint.
How does a cursor work?
What is the difference between cursor and select statement?
What are types of indexes?
Explain about rct in db2?
what is utility for parm lib
What is db2 bind?
In case if at some point of time db2 is down, would that impact the pre-compilation process of a db2-cobol program?
How to fetch the last row from the table in SQL (db2)?
What is rebind in db2?
Who uses db2?
What is clone table?
How does coalesce work?
What is db2 command?
How to run db2 command in windows?