Subject RE: [ib-support] PLAN
Author Nico Callewaert
Thanks Set for your time

Nico

-----Oorspronkelijk bericht-----
Van: Svein Erling Tysvar
[mailto:svein.erling.tysvaer@...]
Verzonden: donderdag 10 mei 2001 10:16
Aan: ib-support@yahoogroups.com
Onderwerp: Re: [ib-support] PLAN


Hi Nico,

>I've used the IB_WISQL to check the plan of my queries. I saw two
different
>things : a PLAN SORT (...) and a PLAN JOIN (...). What is the difference
>between the 2 ? What about performance ?

PLAN SORT will encapsulate the rest of your plan if you order by a
non-indexed field, basically saying that it has to sort the records after
getting the result set. If the result set is small (which it ought to be),
it doesn't affect performance very much at all. In fact, it may be better
than a PLAN JOIN (<tablename> ORDER ...) which will use the index to order
by rather than an index suitable for your WHERE clause (a bad idea, I
think). PLAN JOIN is something you ought to pay a lot closer attention to.
In general, I find it preferrable if the plan uses one index for each table
involved. I guess it could be useful with a few more occationally if the
indexes aren't very restictive, but mostly my queries slow down if using
too many indexes for each table.

HTAY? (Hope this answers your question),
Set

To unsubscribe from this group, send an email to:
ib-support-unsubscribe@egroups.com



Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/