Mur
User
 Platinum Boarder
| Posts: 116 |   | Karma: 0 |
|
CachedUpdates don't work on Master/Detail
|
|
Posted: 2000/08/08 12:14 |
|
|
|
|
I have OCIQueries quMaster, quDetail and DataSources for them dsMaster, dsDetail. I have quDetail.DataSource := dsMaster After I updated both (it is important!) queries (quMaster.UpdatesPending = True and quDetail.UpdatesPending = True) I want to apply changes. I do the following (simplified code): . db.StartTransaction; . try . quMaster.ApplyUpdates; . quDetail.ApplyUpdates; . db.Commit; . quMaster.CommitUpdates; . quDetail.CommitUpdates; . except . db.Rollback; . end; After that quMaster is updated, but quDetail isn't updated, without saying any errors!!! The workaround I found is to clear quDetail.DataSource, apply updates and then restore it. . Sav := quDetail.DataSource; . quDetail.DataSource := nil; // Applying updates (insert above code) . quDetail.DataSource := Sav ;
|
|