开发者

MySQL general query log entry order

When directing MySQL's General Query Log to a general_log table, it has an event_time column of type timestamp - which has a resolution of 1sec. Also there is no auto-increment id column.

If multiple log entries have the same timestamp (occur on same second) 开发者_运维问答- how can I know their order?

(If you know of a completely different approach to logging the queries by their order, please do share as well)


Summing up my understandings and the comments above:

  • General Query Log (GQL) entries are written in the order received, which might differ from the order in which they are executed
  • Indeed GQL has a resolution of only 1sec
  • MySQL's binary log seems the only way to get better resolution
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜