List:Commits« Previous MessageNext Message »
From:rburnett Date:June 15 2007 6:00pm
Subject:Connector/NET commit: r764 - in branches/5.0: . Driver/Source
View as plain text  
Modified:
   branches/5.0/CHANGES
   branches/5.0/Driver/Source/UsageAdvisor.cs
Log:
Bug #29124 Usage Advisor not checking UseUsageAdvisor setting 

Fixed problem where usage advisor warnings for unnecessary field conversions
and not reading all rows of a resultset would output even if you
did not request usage advisor warnings.

Modified: branches/5.0/CHANGES
===================================================================
--- branches/5.0/CHANGES	2007-06-15 17:53:27 UTC (rev 763)
+++ branches/5.0/CHANGES	2007-06-15 18:00:56 UTC (rev 764)
@@ -9,7 +9,10 @@
   - Fixed problem where any attempt to not read all the records returned
     from a select where each row of the select is greater than 1024 bytes
     would hang the driver.
-  
+  - Fixed problem where usage advisor warnings for unnecessary field conversions
+    and not reading all rows of a resultset would output even if you
+    did not request usage advisor warnings. (Bug #29124)
+    
 Version 5.0.7 5/16/2007
 
   Bugs fixed

Modified: branches/5.0/Driver/Source/UsageAdvisor.cs
===================================================================
--- branches/5.0/Driver/Source/UsageAdvisor.cs	2007-06-15 17:53:27 UTC (rev 763)
+++ branches/5.0/Driver/Source/UsageAdvisor.cs	2007-06-15 18:00:56 UTC (rev 764)
@@ -67,7 +67,9 @@
 
 		public void ReadPartialRowSet(string cmdText, bool[] uaFieldsUsed, MySqlField[] fields)
 		{
-			LogUAHeader(cmdText);
+            if (!conn.Settings.UseUsageAdvisor) return;
+
+            LogUAHeader(cmdText);
 			Logger.WriteLine("Reason: Every column was not accessed.  Consider a more focused query.");
 			Logger.Write("Fields not accessed: ");
 			for (int i = 0; i < uaFieldsUsed.Length; i++)
@@ -80,7 +82,9 @@
 		public void Converting(string cmdText, string columnName,
 									  string fromType, string toType)
 		{
-			LogUAHeader(cmdText);
+            if (!conn.Settings.UseUsageAdvisor) return;
+
+            LogUAHeader(cmdText);
 			Logger.WriteLine("Reason: Performing unnecessary conversion on field "
 									  + columnName + ".");
 			Logger.WriteLine("From: " + fromType + " to " + toType);

Thread
Connector/NET commit: r764 - in branches/5.0: . Driver/Sourcerburnett15 Jun