Subject | Re: [ib-support] Optimizer or De-optimizer ? |
---|---|
Author | Ann W. Harrison |
Post date | 2001-03-21T15:21:18Z |
At 11:44 AM 3/21/2001 -0300, Carlos H. Cantu wrote:
One or the other must be accessed naturally since the
look-up value comes from the tables and is not presented
as part of the query. If you have an aquisi, you can find
forns. If you have a forn, you can find an aquisi. If
you have neither, you must start somewhere.
Or is there another problem?
Regards,
Ann
www.ibphoenix.com
We have answers.
>select a.*, f.forn_nome, f.forn_endWhich table is larger, aquisi or forn?
>from AQUISI a
>join forn f on f.cod_forn = a.cod_forn
>
>generated plan :
>
>PLAN JOIN (F NATURAL,A INDEX (RDB$FOREIGN57))
>
>f.cod_forn is the primary key of FORN. Why the optimizer isn't using the
>index in this simple join ????
One or the other must be accessed naturally since the
look-up value comes from the tables and is not presented
as part of the query. If you have an aquisi, you can find
forns. If you have a forn, you can find an aquisi. If
you have neither, you must start somewhere.
Or is there another problem?
Regards,
Ann
www.ibphoenix.com
We have answers.