Results 1 to 2 of 2
  1. #1
    Join Date
    Nov 2005
    Posts
    1

    Unanswered: Outer join query

    Quick question:

    As far as outer joins in Oracle go should this work:

    SELECT *
    FROM a, b
    WHERE a.col1(+) = b.col1
    AND a.col2(+) = 'INFO'

    I just as because I did not think you could have a specific line like:
    AND a.col2(+) = 'INFO' in an outer join.

  2. #2
    Join Date
    Feb 2004
    Location
    Dublin, Ireland
    Posts
    212
    yes, this join works in Oracle such as:
    Code:
    SELECT ename, job, dept.deptno, dname 
        FROM emp, dept 
        WHERE emp.deptno (+) = dept.deptno 
            AND job (+) = 'CLERK'; 
    
    ENAME      JOB       DEPTNO     DNAME
    ---------- --------- ---------- --------------
    MILLER     CLERK             10 ACCOUNTING
    SMITH      CLERK             20 RESEARCH
    ADAMS      CLERK             20 RESEARCH
    JAMES      CLERK             30 SALES
                                 40 OPERATIONS

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •