Try to run this query on enwp on labs:
select log_timestamp, log_action from logging where log_namespace=0 and log_title='Great_Nuclear_Doge_Event' and log_type='delete' and log_timestamp > '20160121065733';
This should be using the indexes, as indicated by the below, but it takes much, much longer to run on labs, any reason why?
Using the logging_userindex table did not help.
mysql:wikiadmin@db1057 [enwiki]> select log_timestamp, log_action from logging where log_namespace=0 and log_title='Great_Nuclear_Doge_Event' and log_type='delete' and log_timestamp > '20160121065733'; +----------------+------------+ | log_timestamp | log_action | +----------------+------------+ | 20160121070000 | delete | +----------------+------------+ 1 row in set (0.08 sec) mysql:wikiadmin@db1057 [enwiki]> explain select log_timestamp, log_action from logging where log_namespace=0 and log_title='Great_Nuclear_Doge_Event' and log_type='delete' and log_timestamp > '20160121065733'; +------+-------------+---------+-------+--------------------------------------------------------------+---------------------+---------+------+------+------------------------------------+ | id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra | +------+-------------+---------+-------+--------------------------------------------------------------+---------------------+---------+------+------+------------------------------------+ | 1 | SIMPLE | logging | range | type_time,page_time,times,log_title_time,log_title_type_time | log_title_type_time | 68 | NULL | 1 | Using index condition; Using where | +------+-------------+---------+-------+--------------------------------------------------------------+---------------------+---------+------+------+------------------------------------+ 1 row in set (0.01 sec)