MySQL Forums
Forum List  »  InnoDB

ADO Transaction via MyODBC
Posted by: Stefano Griggio
Date: July 15, 2005 05:00AM

Hi.
I'm writing a VisualC++ persistent connection application using ADO.
When saving to MySQL I Use transaction as follow :

try
{
pConnection->BeginTrans();

// Some operation

pConnection->CommitTrans();
}
catch(_com_error &e)
{
// error handling
}

If a net error (i.e. server done) occurs in the try block without performing the CommitTrans(),
the transaction seems to be pending.(if I execute again the code, the begintrans()
generate an exception).
How can I abort a pending transaction in ADO?
Must I close the connection?

Thanks, Stefano.

Options: ReplyQuote


Subject
Views
Written By
Posted
ADO Transaction via MyODBC
2899
July 15, 2005 05:00AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.