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: how to prevent a table scan

Re: how to prevent a table scan

From: bocgco <bocgco_at_bocgco.com>
Date: Thu, 29 May 2003 11:44:27 +0800
Message-ID: <3ed581b5$1@shknews01>


Running Oracle in Windows environment will often gives out strange result. This is my limited experiences.

Jerry Dubuke <jdubuke_at_not.gpdservices.com> wrote in message news:3ed4ce76$0$29105$4c41069e_at_reader0.ash.ops.us.uu.net...
> Hi all,
> I have an 8.0.6 Oracle installation. Effectively, I have 2 database with
> identical schemas - one is called AF and one is called UP. I am trying to
> set up a synchronization on a couple of the tables (must be manual for
> multiple reasons...). I have the following query, which uses table scans
> according to the explain plan. Can anyone see a way that I can speed this
> up by forcing it to use indexes? I have indexes set up on sh_seqnum and
> oh_number.
>
> Select
> afsh.sh_moohtype f1,
> upoh.oh_number f2,
> afsh.sh_morefno f3,
> afsh.sh_date f4,
> afsh.sh_qty f5,
> afsh.sh_item f6,
> afsh.sh_seqnum f7,
> afsh.sh_adcukey f8,
> afsh.sh_txseqnum f9,
> afsh.sh_moohnumber f10,
> afsh.sh_rqseqnum f11
> from
> af.sh afsh,
> up.sh upsh,
> up.oh upoh
> where
> (upsh.sh_seqnum(+) = afsh.sh_seqnum and upsh.sh_seqnum is NULL) and
> (upoh.oh_number = 'A' || afsh.sh_moohnumber) and
> afsh.sh_qty > 0
> order by
> afsh.sh_moohnumber,
> afsh.sh_morefno;
>
> Thanks in advance for any help/assistance you can give!!
> Jerry D
>
>
Received on Wed May 28 2003 - 22:44:27 CDT

Original text of this message

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