I\'m working on a Linux host with mysql command. I have a script that runs batch mysql commands (like mysql -e \"select...\") and I wish to summarize execution time
mysql -e \"select...\"
You can use
set profiling=1
and then, later,
show profiles
which will give a list of commands and times.
See http://dev.mysql.com/doc/refman/5.0/en/show-profiles.html
h/t http://ronaldbradford.com/blog/timing-your-sql-queries-2010-07-07/