Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

Define check constraint.

1134


How does a cursor work?

1043


What is the difference between cursor and select statement?

1153


What are types of indexes?

1190


Explain about rct in db2?

1166


what is utility for parm lib

2423


What is db2 bind?

1131


In case if at some point of time db2 is down, would that impact the pre-compilation process of a db2-cobol program?

1096


How to fetch the last row from the table in SQL (db2)?

1698


What is rebind in db2?

1119


Who uses db2?

1114


What is clone table?

1114


How does coalesce work?

1077


What is db2 command?

1091


How to run db2 command in windows?

1248