Subject | Re: Slower fetchall after creating indices |
---|---|
Author | Ali Gökçen |
Post date | 2006-07-03T12:52:56Z |
Hi Adam,
rows fetched. problem is:
you cant find out deleted instanties without full-scan.
so, your flagged as deleted 10 rows may be bottom of table naturally,
(in case of natural scan)
or your deleted rows may be biggest numbers.(in case of indexed scan)
Solution is easy:
create an index on deleted field. you will get in faster way even you
have billion of rows.
Regards.
Ali
FFM#208
>FIRST 10 doesn't effects the speed here, problem is not about 10,000
> SELECT
> FIRST 10
> Instantie.id
> FROM Instantie
> WHERE Instantie.deleted=0
> ORDER BY Instantie.telefoon ASC
>
rows fetched. problem is:
you cant find out deleted instanties without full-scan.
so, your flagged as deleted 10 rows may be bottom of table naturally,
(in case of natural scan)
or your deleted rows may be biggest numbers.(in case of indexed scan)
Solution is easy:
create an index on deleted field. you will get in faster way even you
have billion of rows.
Regards.
Ali
FFM#208