Subject Re: Limiting fetched rows doesn't offer much performance benefit
Author jimbehr3446
--- In firebird-support@yahoogroups.com, "Ivan Prenosil"
<Ivan.Prenosil@...> wrote:
>
> Firebird will first use the index to create list of potentially
matching records,
> then it retrieves first 50 and stops, it will not read all rows
internally.
>
It will not read all of the rows unless all of them match the query
(which can happen sometimes with our situation). So then FB would
read through millions when all we want is the first 50 it finds.

When there is no ORDER BY clause it would be faster for FB to just
return the first 50 that match. But it does not appear to work that
way. And I have not been able to find a workaround.

Thanks for your comments.