Bug #28704 Where to restart transaction ?
Submitted: 27 May 2007 15:00 Modified: 2 Jun 2007 12:41
Reporter: newbie Shai Email Updates:
Status: Not a Bug Impact on me:
None 
Category:Connector / NET Severity:S3 (Non-critical)
Version:1.08 OS:Windows
Assigned to: CPU Architecture:Any

[27 May 2007 15:00] newbie Shai
Description:
Dear All,
        I am developing a windows application using Innodb storage engine and mysql connector/net 1.08. Some time I get a "lock wait time out please restart transation". Below is my final code where I do commit.First of all where actually possible the the time out error occurs ? Is it in the catch section ? So how do I restart my transaction when I get an error of lock wait time out ? Thanks.
 try
    {
       transactionLocal.Commit();
    }
 catch (MySql.Data.MySqlClient.MySqlException ex)
    {
     try
     {
       transactionLocal.Rollback();
     }
     catch (MySqlException ex1)
     {
     MessageBox.Show("An exception of type " + ex.GetType() +
                                          " was encountered while inserting the data.");
     if (transactionLocal.Connection != null)
     {
     Console.WriteLine("An exception of type " + ex1.GetType() +
      " was encountered while attempting to roll back the transaction.");
     }
   }
  }
  finally
  {
   connectionLocal.Close();
  }

How to repeat:
The repetition happens when I get an error due to lock time out and finding a solution for this.
[2 Jun 2007 12:41] Tonci Grgin
We're sorry, but the bug system is not the appropriate forum for asking help on using MySQL products. Your problem is not the result of a bug.

Support on using our products is available both free in our forums at http://forums.mysql.com/ and for a reasonable fee direct from our skilled support engineers at http://www.mysql.com/support/

Thank you for your interest in MySQL.

Explanation:
 Hi newbie :) and thanks for your report. You should start by reading InnoDB section in manual followed by c/NET and finally lists & bugsdb. You'll find a lot of useful information there. Canceling and restarting transaction seems the only way to go.