Microsoft Knowledge Base Article
This article contents is Microsoft Copyrighted material.
©2005-©2007 Microsoft Corporation. All rights reserved.
Terms
of Use |
Trademarks
Article ID: 171613 - Last Review: October 15, 2003 - Revision: 2.0
INFO: Retaining Transactions with Transaction Object
This article was previously published under Q171613
This article explains the relationship of retaining transactions and
transaction object.
An OLE DB application can use ITransactionLocal::StartTransaction to begin
a transaction if the transaction object is supported by providers.
ITransactionLocal is an interface on the session object, and can be
QueryInterface from any other interface on the session object. Information
regarding a transaction can be retrieved by calling the GetTransactionInfo
method.
The Commit or Abort method of the transaction object can be used to commit
or abort a transaction. The Commit and Abort methods allow you to specify
whether or not to retain a transaction. If you do not retain the
transaction object, a new transaction will not be started after the
original transaction is finished, and the transaction object will become
inactive. The only valid action for the transaction object will be to
release it. To retain a transaction, set fRetaining flag to TRUE in the
Commit or Abort method.
The OLE DB Provider for ODBC version 1.1 supports transaction object and commit/abort retaining. Transactions can be committed synchronously, asynchronously, or two-phased, depending on the setting of XACTTC flag. With fRetaining set to TRUE, however, the XACTTC flag must be set to zero. The OLE DB Provider for ODBC version 1.1 does not support any setting of XACTTC flag when fRetaining set to TRUE.
APPLIES TO
- Microsoft OLE DB 1.1
- Microsoft OLE DB Provider for ODBC 1.1
| kbinfo kbprogramming KB171613 |
Retired KB Content DisclaimerThis article was written about products for which Microsoft no longer offers support. Therefore, this article is offered "as is" and will no longer be updated.
Community Feedback System
Very often, it takes hours to solve a problem. Very often, you've looked high
and low, and have tried a lot of solutions. When you finally found it, chances
are, it was because someone else helped you. Here's your chance to give back.
Use our community feedback tool to let others know what worked for you and what
didn't.
Please also understand that the community feedback system is not warranted to be
correct, it's simply a system that we've built to let people try and help each
other. If something in a feedback response doesn't make sense to you, or you're
not comfortable making changes that the feedback talks about (like registry
edits), please consult a professional.
Thank you for using kbAlertz.com Feedback System.
-- Scott Cate