Pages on a MediaWiki wiki are grouped into collections called "namespaces", which differentiate between the purpose of the pages at a high level. Pages in certain namespaces can also have special properties or behave differently when they interact with other pages.

delete from text where old_id IN(
select r.rev_text_id from page p, revision r where p.page_id=r.rev_page and p.page_namespace=1 and p.page_id=687
);
delete from revision where rev_page=687;
delete from page where page_id=687;

mysql -u root -p -D wikidb117 -s -e "select CONCAT(old_id,','),left(old_text,50) from text where old_text like '%xlm%' or old_text like '%crr%' or old_text like '%ptq%' or old_text like '%dkl%' or old_text like '%skl%'" > eliminar.txt
mysql -u root -p -D wikidb117 -s -e "select CONCAT(old_id,','),left(old_text,50) from text where old_text like '%lli%' or old_text like '%jnk%' or old_text like '%pfg%' or old_text like '%sjk%' or old_text like '%dxf%' or old_text like '%sml%' or old_text like '%crk%' or old_text like '%rtg%'" > eliminar.txt