Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: help with index hint
Sorry here's the plan:
Execution Plan
0 SELECT STATEMENT Optimizer=CHOOSE (Cost=2 Card=1 Bytes=61) 1 0 SORT (AGGREGATE)
2 1 NESTED LOOPS (Cost=2 Card=2 Bytes=122) 3 2 TABLE ACCESS (BY INDEX ROWID) OF 'RUN' (Cost=1 Card=2 Bytes=72) 4 3 INDEX (RANGE SCAN) OF 'RUN_RUN_ID_IDX' (NON-UNIQ UE) (Cost=1 Card=2) 5 5 INDEX (UNIQUE SCAN) OF 'SYS_C001378' (UNIQUE)
Thanks,
In article <8ua2ac$aoi$1_at_nnrp1.deja.com>,
David Fitzjarrell <oratune_at_aol.com> wrote:
> In our lasat gripping episode gdas_at_my-deja.com wrote:
> > I've done this many times before, but for some reason, it just won't
> > work today and I can't understand it.
> >
> > I'm trying to specify an index hint to use a specific index in a
table,
> > and oracle is simply ignoring my hint and not using the index I'm
> > telling it to.
> >
> > My looks like this:
> >
> > SELECT /*+ INDEX(RUN RUN_ACCT_ID_IDX) */
> > COUNT(RUN_ID),MAX(RUN_ID),AVG(RUN_ID)
> > FROM
> > RUN A WHERE A.ACCOUNT_ID = 723 AND A.STATUS = 'OK';
> >
> > When I run an explain plan on this statement, it doesn show the
> > specified index in the hint being used.
> >
> > Did I do incorrectly specify the hint? I'm stumped.
> > By the way, this is on 8.1.5.
> >
> > Any ideas appreciated,
> > Gavin
> >
> > Sent via Deja.com http://www.deja.com/
> > Before you buy.
> >
>
> Please provide the query plan -- seeing both the query and the
> execution plan Oracle is using will go a long way to help explain this
> behaviour.
>
> --
> David Fitzjarrell
> Oracle Certified DBA
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
>
Sent via Deja.com http://www.deja.com/
Before you buy.
Received on Tue Nov 07 2000 - 17:19:31 CST
![]() |
![]() |