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: Create index on tables that are joined?

Re: Create index on tables that are joined?

From: <fitzjarrell_at_cox.net>
Date: Tue, 16 Oct 2007 11:21:41 -0700
Message-ID: <1192558901.557104.208130@q3g2000prf.googlegroups.com>


On Oct 16, 12:47 pm, Stick With Hair <StickWithH..._at_gmail.com> wrote:
> I have a table "ABC" which has 2 million records. A second table "XYZ"
> has 10 million records. I am joining ABC to XYZ and want to get all
> the records from ABC and only matches in XYZ (left join).
>
> ABC --> XYZ
>
> On Fields:
> CustName
> CustTitle
> CustPhoneNumber
>
> The table XYZ has an index on those 3 fields but ABC does not. If I
> created an index on those fields in ABC will it help with query
> performance even though I am bringing in all the rows from ABC? I
> would guess that we need indexes on all foreign keys in both tables.
>
> Any Suggestions or ideas?
> Stick with hair

Have you tried creating such an index on ABC and viewing the query plan?

David Fitzjarrell Received on Tue Oct 16 2007 - 13:21:41 CDT

Original text of this message

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