Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
n0i0x
Starting Member
5 Posts |
Posted - 2002-03-01 : 12:06:48
|
| Hi I'm using oracle 8.0i and have built amongst others the following tables. Named PROJECT, EMPLOYEE, AND CONTRIBUTOR (LINKS PROJECT & EMPLOYEE)PROJNO PROJNAME PLDRNIN BUDGET ---------- ------------------------- -------------- ---------- -----SPENT----STARTDATE EXFINISH--------- --------- 1 EXCITING SOFTWARE YK111111D 10000 500001-JAN-02 06-AUG-02 99 BRILLIANT SOFT YK222222D 100000 200002-FEB-01 08-JUN-02EMPNIN LASTNAME FIRSTNAME DIVNO SAL-------------- -------------- -------------- ---------- ----------JOB MGRNIN-------------- --------------YR333333R SMITH BENJAMIN 3 12000PROGRAMMER YR000002DYR222222R JONES MICHAEL 1 12500ANALYST YR000002DYR777777R QUICK PAMELAPROGRAMMERYK111111D CROCKETT KEELEYPROJECT LEADER SQL> SELECT * 2 FROM CONTRIBUTOR; PROJNO EMPNIN---------- -------------- 1 YR333333R 1 YR222222R 1 YR444444R 1 YR888888R 99 YR333333R 99 YR777777R 99 YR100000R 99 YR200000RI want to list any project names which are implemented by both a 'PROGRAMMER' AND an 'ANALYST'?So far my querie looks like thisSELECT p.projname FROM project p, contributor c, employee e WHERE p.projno = c.projno AND e.empnin = c.empnin AND e.job='ANALYST' AND e.job='PROGRAMMER';But this shows project names of those implemented by analyst or programmer and not those which contain both.Any idea's?Much appreciated |
|
|
graz
Chief SQLTeam Crack Dealer
4149 Posts |
|
|
|
|
|