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 specify multiple optimizer hints

Re: How to specify multiple optimizer hints

From: Sybrand Bakker <postbus_at_sybrandb.demon.nl>
Date: Mon, 10 Aug 1998 21:47:00 +0200
Message-ID: <35CF4E33.121D2C43@sybrandb.demon.nl>


Hi Tim,
From the top of my head, it's
D
/*+ USE_NL(CUST) INDEX CUST.CUST_ZIP_IX */ One thing I am sure of: If you do have an alias in your statement, you MUST use the alias in the optimizer hints instead of the table name.

Hth

Sybrand Bakker

Tim Romano wrote:

> I've checked every reference to hand (The Complete Reference, The
> Black Book, Oracle PDF docs, the Oracle How To...) and cannot find
> a section on the syntax for specifying multiple compiler hints.
> The Hints sections I have found do not offer many examples and
> don't go into much detail on how to understand their
> representations of syntax. (e.g. sometimes it's hard to tell if []
> are required or are merely a typographical convention used by the
> author to indicate a value to be supplied.) Since Oracle ignores
> invalid hints, according to the Complete Reference, well... even
> trial-and-error, that trusty friend, is not available. ;-)
>
> I want to use nested loops and indicate also the index to be used
> in that operation. Are any of the following attempts correct,
> where CUSTOMER is the table name, CUST is the alias for that table
> in the SQL from-clause, and the index is named CUST_ZIP_IX?
>
> A.
> /*+ USE_NL(CUST) INDEX CUSTOMER(CUST_ZIP_IX) */
>
> B.
> /*+ USE_NL(CUST) INDEX(CUST_ZIP_IX) */
>
> C.
> /*+ USE_NL(CUST) INDEX(CUSTOMER[CUST_ZIP_IX]) */
>
> Thanks for any help (or doc references),
> Tim
Received on Mon Aug 10 1998 - 14:47:00 CDT

Original text of this message

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