Subject Re: [IBO] Fastest Count
Author Bill Gage
Thank you Lester.

I don't think I fully understand your alternate solution. Do you
mean to populate that table with the counts? In the situation I am
in this is not an option because the actual SQL statement is created
dynamically and there could be an infinite number of variations.

--- In, Lester Caine <lester@l...> wrote:
> Bill Gage wrote:
> > What would be the fastest and most efficient to return the value
> > a SELECT Count(*) statement? What component should be used?
> 1/ Not return it at all. It's very heavy on processing, so if you
have a
> need to return counts on a regular basis think about managing them
in a
> separate table which is updated by INSERT and DELETE triggers.
> 2/ For occasional use, then IB_DSQL is probably the best choice,
> just execute it when ever you need it.
> --
> Lester Caine
> -----------------------------
> L.S.Caine Electronic Services