Daniel
2012-11-05 16:09:32 UTC
Show details of departments and employees including those departments with no employees.
N.B. Try this using an alternative method involving a UNION construct rather than an ‘(+)’ outer join construct.
SELECT ENAME, JOB, DEPT.DEPTNO, DNAME, LOC FROM DEPT, EMP
WHERE EMP.DEPTNO != DEPT.DEPTNO
UNION
SELECT ENAME, JOB, DEPT.DEPTNO, DNAME, LOC FROM DEPT, EMP
WHERE DEPT.DEPTNO = EMP.DEPTNO
Any help is appreciated!