protected override void ClearBatch() { if (commandBatch.Count > 0) { MySqlCommand cmd = (MySqlCommand)commandBatch[0]; if (cmd.Batch != null) cmd.Batch.Clear(); } commandBatch.Clear(); }