Subject Re: Table with more than 100 index.
Author svanderclock
> > ID_place = xxx and
> > Status = 1 and
> > kind = 65 and
> > subcategory = 12
>
> For starters, add a combined index on these columns then. What version of
> Firebird
> are you using? Newer versions keep track of index selectivity in a better
> way.

yes, this what i do. we have firebird 2.1.2 but i thing nothing change about this in 2.1.3



> > in the case yes can be < 10000 row, but just changing kind = 65 by kind =
> > 64 will output 2 000 000 row !
>
> But the user won't neeed 2 000 000 rows, would he?

no of course (always max 200 first records), but he want the result ordered ;)



> Why do you want to return 10 000 rows? Is that a resultset the user wants too?

no just 200 first row, but as i say ordered ... and it's the order by that is the most intensive here. he can order the record by this or this or this ... so not really easy !


> If you have a lot of indices, adding data will be "heavy" on the system.
> Don't use that many indices, drop all indices and start over.

i know but what other choice ?


thanks again !
stephane