Bug #13326 | SQLPS statement logging is incomplete in 5.0 | ||
---|---|---|---|
Submitted: | 19 Sep 2005 16:12 | Modified: | 25 Jul 2007 3:39 |
Reporter: | Paul DuBois | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server: Prepared statements | Severity: | S3 (Non-critical) |
Version: | 5.0.13 and up | OS: | Any |
Assigned to: | Konstantin Osipov | CPU Architecture: | Any |
[19 Sep 2005 16:12]
Paul DuBois
[12 Jul 2007 19:14]
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/commits/30831 ChangeSet@1.2518, 2007-07-12 23:14:00+04:00, kostja@bodhi.(none) +1 -0 Apply community contributed fix for Bug#13326 SQLPS statement logging is incomplete in 5.0 (and review fixes). When in 5.0.13 I introduced class Prepared_statement and methods ::prepare and ::execute, general logging was left out of this class. This was good for stored procedures, since in stored procedures we do not log sub-statements, but introduced a regression in case of SQL syntax for prepared statements, as previously we would log the actual statements to the log, and after the change we would log only COM_QUERY text. Restore the old behavior, but still suppress logging if inside a stored procedure. Based on a community contributed patch from Vladimir Shebordaev. No test case since we do not have a mechanism to test output of the general log.
[12 Jul 2007 19:29]
Konstantin Osipov
Queued into 5.0-runtime
[17 Jul 2007 15:30]
Bugs System
Pushed into 5.0.48
[17 Jul 2007 15:30]
Bugs System
Pushed into 5.1.21-beta
[25 Jul 2007 3:39]
Paul DuBois
Noted in 5.0.48, 5.1.21 changelogs. For the general query log, logging of prepared statements executed via the C API differed from logging of prepared statements performed with PREPARE and EXECUTE. Logging for the latter was missing the Prepare and Execute lines.