BDE seems to lose track of which cached updates have been made to the database

BDE seems to think it has already applied certain updates after an
constraint error from a database.

This problem should be easy to duplicate.  Drop a database, a table, a
datasource, a grid, and a button on a form.  Tie the data aware controls
together ( I am using a SQLServer database).  Enable cached updates on the
table.  Invoke the ApplyUpdates method on the database from the ButtonClick
method.

Run the program and make changes to several existing records in the grid.
Make sure one of the changes (not the first one made) will violate a
constraint on the table.  (You can run SQLTrace to see exactly what happens
on the database side).  It will start a transaction, start applying the
changes in the order that you made them, then hit the constraint violation.
 The transaction will be rolled back and an exception will be raised.  If
you correct the offending record and ApplyUpdates again then the only
changes that actually get posted to the database are the one for what was
the offending record and any changes that were made after the first change
to the offending record.  All changes that were made before you changed the
offending record are not applied to the database.  The grid still shows
these changes until you fetch from the database again.  It's like there is
a pointer into the updates and it did not get reset to start at the
beginning of the cached updates again after the rollback of the
transaction.

This problem is further complicated in a master/detail relationship.  If
you have listed the master table first in the ApplyUpdates call on the
database and an error is generated on a detail record, then on the second
ApplyUpdates, changes to the master table will not made as well as those
changes made before the change to the detail that was originally rejected.

Does anybody know what I am doing wrong or how to work around this problem?