Subject | Re: [IBO] Re: SQL plan in TIBOQuery |
---|---|
Author | Jason Wharton |
Post date | 2003-02-03T22:59:29Z |
Also remember, if it is pulling in too many indexes there are tricks you can
do to suppress their inclusion. For example:
SELECT *
FROM ATABLE
WHERE ACOLUMN + 0 = AVALUE
Adding the + 0 will make it so that the optimizer will not include an index
for that column.
HTH,
Jason Wharton
CPS - Mesa AZ
http://www.ibobjects.com
-- We may not have it all together --
-- But together we have it all --
do to suppress their inclusion. For example:
SELECT *
FROM ATABLE
WHERE ACOLUMN + 0 = AVALUE
Adding the + 0 will make it so that the optimizer will not include an index
for that column.
HTH,
Jason Wharton
CPS - Mesa AZ
http://www.ibobjects.com
-- We may not have it all together --
-- But together we have it all --
----- Original Message -----
From: "Aage Johansen" <aagjohan@...>
To: <ibObjects@yahoogroups.com>
Sent: Monday, February 03, 2003 12:22 PM
Subject: [IBO] Re: SQL plan in TIBOQuery
> >Another thing you can do is anticipate all the possible orders
> >and provide indexes for them so that the optimiser has something
> >better to choose from.
>
> Alternatively: You should also try to _remove_ the index that is used for
> sorting (if this does not also remove indexes used in the WHERE
> clause. Even 'bending' the query to avoid ordering by an index can be a
> good thing. IB/Fb usually sorts quite fast, but when it tries to use an
> index for the ORDER BY it often slows down.
> YMMV
>
> --
> Aage J.
>
>
>
___________________________________________________________________________
> IB Objects - direct, complete, custom connectivity to Firebird or
InterBase
> without the need for BDE, ODBC or any other layer.
>
___________________________________________________________________________
> http://www.ibobjects.com - your IBO community resource for Tech Info
papers,
> keyword-searchable FAQ, community code contributions and more !
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>
>