Subject Re: [IBO] SqlWhereItems vs Params
Author Daniel Rail
At 21/10/2002 02:38 PM, you wrote:
>Hi All,
> Is there any difference between preferred usage
>and speed gain over using either SqlWhereItems
>or Params, or even rebuilding the SQL statement
>of a TIB_Query when it is used in a master/detail
>situation?
>Any thoughts?

If you already know the params, then just use params and have the query
prepared. When using SQLWhereItems in OnPrepareSQL, or rebuilding the SQL
statement any other way, the query has to be prepared everytime, which can
cost you time. I use params when the query doesn't change, but just the
comparison values. And, I use SQLWhereItems in the OnPrepareSQL event when
I want a dynamic WHERE clause. Also, I only rebuild the query if the
result fields have to change, which is rare.


Daniel Rail
Senior System Engineer
ACCRA Group Inc. (www.accra.ca)
ACCRA Med Software Inc. (www.accramed.ca)