how to customize `show processlist` in mysql?

前端 未结 6 968
孤城傲影
孤城傲影 2021-01-29 18:11

I want to order by Time,but seems no way to do that ?

mysql> show processlist;
+--------+-------------+--------------------+------+---------+--------+--------         


        
6条回答
  •  清酒与你
    2021-01-29 18:43

    Another useful tool for this from the command line interface, is the pager command.

    eg

    pager grep -v Sleep | more; show full processlist;
    

    Then you can page through the results.

    You can also look for certain users, IPs or queries with grep or sed in this way.

    The pager command is persistent per session.

提交回复
热议问题