Subject | "Failed to post all datasets" - new observations |
---|---|
Author | Aage Johansen |
Post date | 2008-07-08T18:55:32Z |
In April, I posted this:
-------------------------------------
Delphi/2007
IBO/4.8.7
Firebird 1.5.4
I've recently encountered (for the first time, and in an old project)
the exception E_Failed_To_Post_Datasets: "Failed to post all datasets".
It is raised in IB_Components: TIB_Transaction.SysPostAll - at least,
that's the only place I found it referenced in the IBO source.
I'd like to hear any hints about something to check...
It happens when I delete a record from a grid (actually, two grids
behave like this). It seems to happen only when there are other rows
present in the grid - deleting the last rows in a grid works ok. The
tables feeding the grids (through TIB_Queries) hold >1mill and >3mill
rows, but the selections in the grids are usually just a few rows.
The TIB_Queries use the same transaction.
The deletes are initiated through clicking the delete button on a
TIB_Updatebar.
Anyway, after clicking the button on the error dialog, the deletes go
through sucessfully.
-------------------------------------
No one responded, but recently I got this comment:
-------------------------------------
A little late, but..
From memory, this happens when you have more than one dataset in the
same transaction. For commit to work, they all have to be in the
same state ie all of them in browse.
-------------------------------------
I thought this strange, and answered:
-------------------------------------
Could this - datasets being in different _states_ - really be a problem?
-------------------------------------
And the response was:
-------------------------------------
Yes, that's where I have seen it. It was in master/detail linked
datasets where one was posted and was not (I think) OR one was in
browse mode and the other in edit.
I got sick of these errors and have coded the stuff with separate transactions.
-------------------------------------
Now, I would like to have this confirmed (or not) - if
possible. Further comments are also welcome!
TiA
Aage J.
-------------------------------------
Delphi/2007
IBO/4.8.7
Firebird 1.5.4
I've recently encountered (for the first time, and in an old project)
the exception E_Failed_To_Post_Datasets: "Failed to post all datasets".
It is raised in IB_Components: TIB_Transaction.SysPostAll - at least,
that's the only place I found it referenced in the IBO source.
I'd like to hear any hints about something to check...
It happens when I delete a record from a grid (actually, two grids
behave like this). It seems to happen only when there are other rows
present in the grid - deleting the last rows in a grid works ok. The
tables feeding the grids (through TIB_Queries) hold >1mill and >3mill
rows, but the selections in the grids are usually just a few rows.
The TIB_Queries use the same transaction.
The deletes are initiated through clicking the delete button on a
TIB_Updatebar.
Anyway, after clicking the button on the error dialog, the deletes go
through sucessfully.
-------------------------------------
No one responded, but recently I got this comment:
-------------------------------------
A little late, but..
From memory, this happens when you have more than one dataset in the
same transaction. For commit to work, they all have to be in the
same state ie all of them in browse.
-------------------------------------
I thought this strange, and answered:
-------------------------------------
Could this - datasets being in different _states_ - really be a problem?
-------------------------------------
And the response was:
-------------------------------------
Yes, that's where I have seen it. It was in master/detail linked
datasets where one was posted and was not (I think) OR one was in
browse mode and the other in edit.
I got sick of these errors and have coded the stuff with separate transactions.
-------------------------------------
Now, I would like to have this confirmed (or not) - if
possible. Further comments are also welcome!
TiA
Aage J.