Subject Re: [IBO] Screen Refresh after changing SQLWhere clause to slow
Author Woody (TMW)
From: "Frank" <FrankBKK@...>
> I use a TIB_Query to access a table where I store two kind of
> informations - normal products and spareparts data.
> in my application I use a TpageControl to display them
> separated but on a single form anyway.
> Switching the Tabs between Spareparts and Products I have to
> change the SQLWhere clause like
> iqProducts.SQLWhere.Text := 'WHERE PRODUCTS.PRODUCT_TYP=''SPT''';
> To immediately refresh the screen and show the new data I have to
> iqProducts.Prepare;
> iqProducts.FetchAll;
> iqProducts.Next;
> The problem is that this way is quit slow -
> but without the FetchAll my screen will not be updated !
> How can I refresh the screen data more faster after
> changing the SQLWhere clause ?

Try Close, Open instead and see if the performance increases. Also, instead
of preparing each time, you can make the product type a paramater and simply
change the parameter instead of the entire where clause.

Woody (TMW)