Subject Re: [IBO] PreparedEdits does not work as expected?
Author Michael Fung <ibo@cmsweb.com>
Dear Helen,

Perhaps you are right, but I would think "a DSQL statement for just
the updated columns should be constructed and immediately executed"
means skipping the prepare stage. For example, a table with many
large fields, it will save traffic by only sending the changes
instead of all data fields. If you use one prepared update statement,
you will send all data fields.


Thanks,
Michael


--- In IBObjects@yahoogroups.com, Helen Borrie <helebor@t...> wrote:
>
> Michael,
> I think Svein's interpretation is right.
>
> The default behaviour by the BDE was to hold a prepared statement
that
> updates every field in the dataset, regardless of how many fields
were
> changed. You can have that behaviour by setting PreparedEdits
> false. IBO's default behaviour is PreparedEdits true, whereby no
> "UpdateAll" prepared statement is created; instead, at posting
time, IBO
> constructs a DSQL statement that updates only the fields that have
changed.
>
> Here's the help text for the PreparedEdits property
> This property determines whether all updates are performed through
a
> prepared DSQL statement or whether a DSQL statement for just the
updated
> columns should be constructed and immediately executed (the
default).
>
> This is saying that the statement is immediately executed, not that
it is
> being submitted with a called to ExecuteImmediate.
>
> As you rightly observe, ExecuteDML encapsulates a call to one of
the
> ExecuteImmediate functions - two special-case calls that don't do a
prepare
> before submitting the statement.
>
> FUpdateSQL.EditSQL uses a regular statement that goes through the
normal
> cycle of preparing (if necessary) and executing via a call to
Execute.
>
> Helen