SELECT and JOIN
https://www.mysqltutorial.org/mysql-inner-join.aspx
Time/date
http://www.richardlord.net/blog/dates-in-php-and-mysql
http://www.tizag.com/perlT/perlmysqlquery.php
http://bytes.com/serversidescripting/perl/tutorials/perlandmysql-together/index.html
http://weblogs.sqlteam.com/jeffs/archive/2007/01/02/56079.aspx
http://www.bennadel.com/blog/172-Ask-Ben-Selecting-Parts-of-a-Date-Time-Stamp-In-SQL.htm
Performance
Checking for errors in all tables/databases
Alternately:
mysqlcheck -c -u root -p --all-databases
Repair a database
mysqlcheck -r DATABASE_NAME -u root -p