Subject | Re: [firebird-support] Re: Firebird 2.0 Indexing |
---|---|
Author | Arno Brinkman |
Post date | 2005-06-01T12:50:14Z |
Hi,
but 1 value is in only 1% of the records.
For example a table with a boolean field History. When the records are processed by a routine the
HISTORY field is set to true, selecting all records which aren't processed yet by a query using an
index on History is fast.
are always welcome to the development team.
Regards,
Arno Brinkman
ABVisie
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Firebird open source database (based on IB-OE) with many SQL-99 features :
http://www.firebirdsql.org
http://www.firebirdsql.info
http://www.fingerbird.de/
http://www.comunidade-firebird.org/
Support list for Interbase and Firebird users :
firebird-support@yahoogroups.com
Nederlandse firebird nieuwsgroep :
news://newsgroups.firebirdsql.info
>> Drop the index on Store_No, the selectivity is too poor for the indexYes, there are certainly cituations where the index does help. When a field contains only 2 values,
>> to be useful (your GROUP BY query should execute somewhat faster
>> without this index, probably equal to your DISTINCT query).
>
> And why doesn't FB automatically ignore an index with such bad
> selectivity in this situation? Is there *any* situation where this index
> should actually be used? I doubt it. So the engine should ignore it.
but 1 value is in only 1% of the records.
For example a table with a boolean field History. When the records are processed by a routine the
HISTORY field is set to true, selecting all records which aren't processed yet by a query using an
index on History is fast.
> This is just one example of a performance pitfall with FB that couldPitty enough, you can't say that so simple else we would aready fixed that. Good ideas/suggestions
> probably be fixed.
are always welcome to the development team.
Regards,
Arno Brinkman
ABVisie
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Firebird open source database (based on IB-OE) with many SQL-99 features :
http://www.firebirdsql.org
http://www.firebirdsql.info
http://www.fingerbird.de/
http://www.comunidade-firebird.org/
Support list for Interbase and Firebird users :
firebird-support@yahoogroups.com
Nederlandse firebird nieuwsgroep :
news://newsgroups.firebirdsql.info