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: ref cursor slow compared to sql query

Re: ref cursor slow compared to sql query

From: Allan Streib <streib_at_cs.indiana.edu>
Date: 30 Jun 2004 17:02:15 -0700
Message-ID: <e334e4a7.0406301602.6b3128ac@posting.google.com>


"Jonathan Lewis" <jonathan_at_jlcomp.demon.co.uk> wrote in message news:<cbuj4i$fpq$1_at_hercules.btinternet.com>...

[...]

> One dirty option is to use the 'selectivity'
> hint, e.g. /*+ selectivity (t1 0.01) */ to tell the optimizer
> that the single-table predicates (in this case your list)
> will typically return a fixed fraction of the data, or the
> cardinality hint e.g. /*+ cardinality(t1 50) */ to tell
> the optimizer how many rows the single-table predicates
> will return. It's not a nice solution (and selectivity()
> seems to be broken in 10g anyway).

Are these hints "undocumented" or otherwise not officially encouraged?  I ask because I perused the SQL Reference looking for any hint that might help be get a better query plan and did not see either of those documented.

Allan Received on Wed Jun 30 2004 - 19:02:15 CDT

Original text of this message

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