I'd like to be able to retrieve a list of users who created pages in the Talk namespace that end in "/GAn". For GA5, for example, I wrote this:
select p.page_title,p.page_id,r.rev_timestamp, u.user_name
from page p
inner join revision r
on p.page_id = r.rev_page
inner join actor a
on r.rev_actor = a.actor_id
inner join user u
on a.actor_user = u.user_id
where p.page_title LIKE '%a/GA5'
and r.rev_parent_id = 0
and p.page_namespace = 1
but it executes extremely slowly. Eliminating the joins to actor and user makes it run in a few seconds, so why is this slow? I would have thought it would pick up the indexes on actor and user on those fields.