Subject locate question
Author Kjeld Loozen
Hello all,

I´ve this IB_Query:

SELECT PRODCODE, ACTCODE, DISC_CODE, SUM(1) AS SUMAANTAL, SUM(DUUR) AS
SUMDUUR
FROM ACT
GROUP BY PRODCODE, ACTCODE, DISC_CODE
ORDER BY PRODCODE, ACTCODE

This query aggregates thousands of records into ± 40, due to the sum
fucntion.
I set the autofetchall property to true.

In my App, I have to locate a perticular record of that query.
I use: IB_Query.locate('PRODCODE;ACTCODE',prod,act,[])

My problem is, that this locate makes IBO generate a new query, like:
SELECT PRODCODE, ACTCODE, DISC_CODE
FROM ACT
GROUP BY PRODCODE, ACTCODE, DISC_CODE
(brilliant, this IB_monitor, btw!)

This query is executed every time a do this locate.
This realy slows down the app. I wrote a similar routine with the BDE some
time ago, and it didn't fire a separate query each time the locate was
executed.

Why does this happen?
Is there a way around, so that the locate seeks his results in memory?

Regards,
Kjeld