Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Outer join with each record

Outer join with each record

From: <aishwan_at_gmail.com>
Date: 1 Sep 2006 06:04:50 -0700
Message-ID: <1157115890.201755.35940@h48g2000cwc.googlegroups.com>


hi

i want to show each outer join with each records.

SQL> SELECT D.DEPTNO,E.ENAME
  2 FROM EMP E,DEPT D
  3 WHERE D.DEPTNO=E.DEPTNO(+);    DEPTNO ENAME
--------- ----------

       10 CLARK
       10 KING
       10 MILLER
       20 SMITH
       20 ADAMS
       20 FORD
       20 SCOTT
       20 JONES
       30 ALLEN
       30 BLAKE
       30 MARTIN
       30 JAMES
       30 TURNER
       30 WARD
       40
       50

17 rows selected.

But i want

   DEPTNO ENAME
--------- ----------

       10 CLARK
       20 CLARK
       30 CLARK
       40 CLARK
       50 CLARK
       10 KING
       20 KING
       30 KING
       40 KING
       50 KING
       10 MILLER
       20 MILLER
       30 MILLER
       40 MILLER
       50 MILLER

.
.
.

so on for each employ record with outer join

please help it is not homework.

aishwan Received on Fri Sep 01 2006 - 08:04:50 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US