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: I just want to join to one more table!

Re: I just want to join to one more table!

From: <jdarrah_co_at_my-deja.com>
Date: Wed, 27 Dec 2000 21:48:13 GMT
Message-ID: <92do2r$vit$1@nnrp1.deja.com>

what does the explain plan show for both queries? In article <92dlvu$tlv$1_at_nnrp1.deja.com>,   jimbo1155_at_my-deja.com wrote:
> I have a query that joins to several tables, and becomes very
> inefficient. It basically looks likes what's below. Now, activity
 has
> about 4m rows, and the contact records have about 1m each.
> The query takes about 80 seconds.
> If I remove either contactaddress or contactphone, it goes down
> to 6 seconds.
>
> I've tried using subqueries, thinking that the subqueries will execute
> independent of anything else, but that doesn't seem to be the case.
>
> Do you think it's the nature of the query? Or perhaps I've hit
> some memory limit where resources have suddenly gotten scarce.
>
> select
> contact.name
> contactaddress.address
> contactphone.phone
>
> from
> activity,
> contact,
> contactaddress,
> contactphone
> where
> activity.id = 1
> and activity.cid = contact.cid
> and contact.aid = contactaddress.aid
> and contact.aid = contactphone.aid
>
> Sent via Deja.com
> http://www.deja.com/
>

Sent via Deja.com
http://www.deja.com/ Received on Wed Dec 27 2000 - 15:48:13 CST

Original text of this message

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