Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Oracle should have a new hint "INDEX_COL(tname,colname)".
oracle_doc wrote:
> AnySQL (d.c.b.a) wrote:
> > The "INDEX" hint let Oracle automatically choose index, however if
> > Oracle can introduce a new hint "INDEX_COL", it will really helpful.
> >
> > Because we may use different index name for the same table in different
> > environment (PROD vs QA).
> >
> > And to use column on specific column is easy for developer to
> > understand.
> >
> >
> >
> > Welcome, AnySQL
> > =======================
> > http://www.anysql.net/en
>
>
> Actually, it's already there!
>
> In 10g, there is an improved version of INDEX hint
>
> INDEX(tab1 tab1(ind_col1, ind_col2))
>
>
> By specifying the index columns rather than the index name, Oracle can
> pick up any index with these columns as the leading portion of the
> index key. When you think about it it's a much better hint, approaching
> the problem from the right direction - the search criteria from the
> logical perspective rather than a particular physical object.
Hi, oracle_doc,
You're one of the few gentlemen that have good memory! About this day last year, Jonathan Lewis told us this (still) undocumented feature
http://groups.google.com/group/comp.databases.oracle.server/browse_frm/thread/de056ba01e68c621
See message 9 and later.
If you see it documented anywhere, let us know.
Regards,
Yong Huang Received on Mon Mar 06 2006 - 21:36:45 CST