Subject RE: [IBO] Updating updated fields only
Author Jason Wharton

> Is there a way to tell IBO datasets (either native or
> TDataset compatible)
> to update only those fields that have changed. My current
> issue is with the
> TIB_Query.
> If I remember correctly, the TQuery had an UpdateMode which
> lets us specify
> upWhereAll, upWhereChanged, upWhereKeyOnly.
> I *really* hope IBO has this functionality.

IBO does have some ways to influence things along these lines.

There is a property PreparedEdits that determines if only changed fields are
included in the UPDATE SQL that is sent to the server or if a prepared
UPDATE SQL is held for all fields and kept prepared and every time a change
is posted all column values are submitted. By default it uses a prepared
edit statement and submits all column values. Setting it to false allows
IBO to generate a unique SQL for each record posting including only changed

As for how the records are referenced IBO uses keys only when possible
unless CachedUpdates is true. This is because with IBO it is generally
expected that you are using the conflict resolution capabilities of the
server instead of coming up with some way to compensate (because most server
products on the market did a very lousy job and you had to work around
them). If you are using CachedUpdates then you are taking full
responsibility of conflict resolution and the default mode for that is to
only allow a record to be updated if it is still reflecting the old values
on the server as the client has them in it buffer. If those values do not
match up then someone else has already updated the record and the buffers on
the client with pending changes are invalid.

In your case, you sound like you are doing a CachedUpdates kind of conflict
resolution model. Are you actually using cached updates too?

Jason Wharton