RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TDBDataSet.PSEndTransaction Method

Ends a transaction that was started by a call to PSStartTransaction.

Pascal
procedure PSEndTransaction(Commit: Boolean); override;
C++
virtual __fastcall PSEndTransaction(Boolean Commit);

The provider component applies updates within a transaction, if possible. To do so, it uses PSEndTransaction in conjunction with the PSStartTransaction method.  

The Commit parameter indicates whether the dataset should commit the current transaction (Commit is true), or roll it back (Commit is false).

Note: TDataSetProvider only starts a transaction (Using PSStartTransaction) if the PSInTransaction method indicates that there is no transaction already established. That is, it does not assume nested transaction support is available. Thus, there is no need to ensure that PSEndTransaction does not terminate a transaction that was not started by the provider.
 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!