How to enable MySQL global log to table

Sometimes is useful to monitor queries during development especially when debugging. So when I need to debug MySQL query, I go to the database and execute these commands:

SET global general_log = 1;
SET global log_output = 'table';

Then go to MySQL database table general_log, and see executed queries.

Leave a Reply

Your email address will not be published. Required fields are marked *