Subject ApplyUpdates seems not to update DB directly
Author Antonio Cambule (STUEBER SOFTWARE)
Hi,

Enrivonment: FB 1.5.x, WinXP, Delphi 7 with IBX 7.07

Scenario:

* 1 x Connection to Database.
* Access with: TIBQuery - TDataSetProvider - TClientDataSet
(Set of Access Components).
* Transaction default is set to TACommit (commit).

My Application has different forms that show different data of my DB.
Every Form has it's own DataModule that will be created when
Form is created and will be destroyed when Form is destroyed.
The most forms have PageControls, which open and close Master- and
Details Data depending on which Page the user browses.
DataModules hold the IBX Access components (TibQuery...) and almost one
Transaction Component for all Sets of Access components in this module.

What I do:

- I go to Form A
- Form A is created and shown, DataModule is created and Data is opened.
- I change something, klick on save and it will be posted.
- On AfterPost Event an Applyupdate is made.

Data should be saved in Database now, am I wrong?
Since here seems to be all right.


- I change to Form B.

< DataModule of Form A is has been destroyed. All Datasets of them are
closed etc. >

- Form B is created and shown, new DataModule for Form B
is created and Data is opened.
- An similar Data as in Form A will be opened to the same Table.
- New DataModule, new Query, new Transaction.


Problem:

The Data is not updated. I get the state before the changes were made.


What I know:

When I close and restart my App and I go Form B then all is fine.
And the new state is shown.

But I don't want to close and reopen my App everytime I change something.

Hope someone can help on this.

thanks and regards
Antonio Cambule