Fork of red links caused by moving pages without leaving a rediredt behind by Saeidpourbabak
This query is marked as a draft This query has been published by Yamaha5.

SQL

AخA
 
USE fawiki_p;
SELECT DISTINCT concat('# [[',log_title,']]'),COUNT(pl_title),log_params 
FROM logging JOIN pagelinks ON pl_title=log_title AND pl_namespace=log_namespace
WHERE log_type='move'
AND log_namespace=0
AND pl_from_namespace=0
AND log_params LIKE '%dir";s:1:"1";}'
#AND log_timestamp >20160600000000
#AND log_user_text='MammothBot'
AND NOT EXISTS (
  SELECT null
  FROM page
  WHERE page_title=log_title AND page_namespace=log_namespace
)
GROUP BY pl_title
ORDER BY COUNT(pl_title) DESC
;
By running queries you agree to the Cloud Services Terms of Use and you irrevocably agree to release your SQL under CC0 License.
All SQL code is licensed under CC0 License.

Checking query status...