Bug #9968 slow query log contains useless entries
Submitted: 18 Apr 2005 11:31 Modified: 7 Aug 2005 1:23
Reporter: Georg Richter
Status: Closed
Category:Server Severity:S1 (Critical)
Version:5.0 OS:Any (all)
Assigned to: Georg Richter Target Version:

[18 Apr 2005 11:31] Georg Richter
Description:
When using prepared statements the slow query log contains no information about the
statement itself, which makes it impossible to optimize statements:

<cut>
# Time: 050418  1:45:41
# User@Host: SAPMY1[SAPMY1] @  [10.17.70.89]
# Query_time: 103  Lock_time: 0  Rows_sent: 483077  Rows_examined: 483077
# administrator command: Execute;
</cut>

How to repeat:
-
[26 Jul 2005 1:05] Boris Burtin
I would definitely like to see this fixed.  The slow query is instrumental in helping me
find performance problems.  It would be great if all problematic were logged reliably.
[27 Jul 2005 12:38] Georg Richter
MySQL 4.1.14 works ok, so the bug is only in 5.
[27 Jul 2005 12:47] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/internals/27630
[30 Jul 2005 0:16] Georg Richter
fixed in 5.0.11
[7 Aug 2005 1:23] Mike Hillyer
Documented in 5.0.11 changelog:

<listitem><para>
 Prepared statements were not being written to the Slow Query log. (Bug #9968)
</para></listitem>
[8 Aug 2005 21:34] Boris Burtin
I saw this in 4.1.10a.  I'll check the logs once we upgrade to 4.1.14 or later to see if
it's still happening.