Bug #64190 Log failed queries in a separate log
Submitted: 1 Feb 2012 6:50 Modified: 1 Feb 2012 9:47
Reporter: Abhijit Buchake Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Server: Logging Severity:S4 (Feature request)
Version:5.5 OS:Any
Assigned to: CPU Architecture:Any
Tags: Failed queries log

[1 Feb 2012 6:50] Abhijit Buchake
Description:
Request to add new feature: 

Please add failed-query-log in MySQL to log all failed queries separately. 

Currently all queries are logged in General Log but this does not specify if the query is failed or executed successfully.

Though failed queries could be handeled in the Application Layer, not many are designed to do so.

If MySQL logs all failed queries in a separate log along with query time and user info, it would be of great help for dibugging issues.

Many Thanks.
Abhijit Buchake

How to repeat:
NA

Suggested fix:
Add new feature to log failed queries separately in a new log (say failed-query-log).
[1 Feb 2012 9:47] Valeriy Kravchuk
Yes, it makes sense either to add column with error (if any) for every statement in general query log, or add option to log failed queries elsewhere.