Need more info about TOracleDataSet.CommitProviderTransaction

benh

Member
Hi,

I'm running D7, DOA 3.4.6.4.
I need to be able to perform some code just prior to the final commit but after all provider BeforeUpdateRecord events have fired (for certain providers only).
I've considered altering Dan Miser's cdsUtil code, but I'd rather stick to native code if possible.
There's been mention made of an unpublished property of TOracleDataSet called CommitProviderTransaction, but I can't seem to get any information on how to use it.
Is this the correct direction to be headed in? and if so, would anyone have a simple code example ?

------------------
 
If the tun-time property CommitProviderTransaction is set to False, the updates that are applied through a TDataSetProvider are no implicitly committed. You can provide your own transaction management in this situation, and commit or rollback when appropriate. I'm not sure if this meets your requirements though.

------------------
Marco Kalter
Allround Automations
 
Thanks for your reply.

I should have mentioned that I'm running a multitier app using Midas.

This property sounds like what I need, however, I'm still not sure where this commit would go.
To simplify what I'm looking for, I wish there were an event on the provider or TOracleSession called "BeforeCommit". I want to do some special processing at this point just before updates are committed.
Where would I perform the commit (if I use CommitProviderTransaction), or how could I trap this ?

------------------
 
You would have to add an EndTransaction function in the server application that is called from the client when the transaction is finished. This would execute a TOracleSession.Commit or Rollback, and allows you to perform any additional processing before or afterwards.

------------------
Marco Kalter
Allround Automations
 
Back
Top