skipping slow query log
If I save a statement in a text开发者_如何学Go file and call it at command prompt like this...
mysql -uroot -pPassWord DB_Name < somefile.txt
The statements taking a long time do not appear in the slow query log even though all the statements do appear in the general and binary logs. Is it a bug?
Is it a bug where?
For all I know, the slow query log could be disabled, or your long-running statements could run in less time, than @@long_query_time
or examine less, than @@min_examined_row_limit
rows.
EDIT:
Well, here is your answer then. Actually, I was never aware of the fact, that it's possible to log statements such as alter table
to the slow query log. It appears, however, that it can be done.
Reference: log-slow-admin-statements.
精彩评论