Subject Re: [IBO] does a tiboquery in a prepared state consume resources on the server?
Author Robert Schuff
Excellent! Thanks Jason. I'll check it out.

my seemingly odd question was asked in the context of Asta and IBO.
Asta Providers interrogate their associated datasets for Parameters
(through the tparams property) then stream the tparams down to the
client-side dataset. I'm constructing tiboqueries dynamically (on the
asta server) assigning only the sql property and need a way to have
them prepared at the right time (just before the provider interrogates
their tparams property) so the provider actually sees the params.

If all I do with the TIBOQuery is assign the SQL property (and do
define the tparams at design time) the provider doesn't know to call
the tiboquery's prepare statement first. Looks like your solution
would be perfect.

thanks much!


"IB Objects" wrote:

> > subject line says it all. If I open an application and call
> > prepare for
> all
> > of my queries, will this consume FB/IB server resources?
> Yes, but you can make a method call which will release the handle
> back to the server and leave the query in its prepared state. It will
> have to do the prepare again if you attempt to open it but that
> shouldn't be too expensive.
> There is a method called FreeServerResources (I think) that will
> release the handle back. This even works for a dataset with all
> records fetched into memory.
> There could be a couple glitches with this feature yet so use it
> carefully.... I'm still trying to make sure it is 100% effective. I
> have to safeguard every possible usage of the handle and
> transparently restore it and I may not have caught every angle of
> usage.
> This is actually foundational development towards allowing even the
> connection handle to go away and be brought back on demand.
> Functionality of IBO v4.5.
> Regards,
> Jason
Rob Schuff
Posted with XanaNews