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

Home -> Community -> Usenet -> c.d.o.server -> Re: Is this JOIN good ?

Re: Is this JOIN good ?

From: Martin T. <bilbothebagginsbab5_at_freenet.de>
Date: 16 Oct 2006 08:03:54 -0700
Message-ID: <1161011034.191599.308300@i3g2000cwc.googlegroups.com>


klabu wrote:
> Assuming you don't know anything about these 3 tables beyond FK & PK
>
> select *
> from A, B, C
> where A.fk = C.pk
> and B.fk = C.pk
>
> Is this JOIN "complete" ?
> or an additional predicate is needed between A and B ?
>

It should be complete.
What I'm not sure though is whether the CBO will come up with different plans when you supply the infered predicate A.fk = B.fk

Just look at the EXPLAIN PLAN with and without and see what it does.

cheers,
Martin Received on Mon Oct 16 2006 - 10:03:54 CDT

Original text of this message

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