This query is marked as a draft This query has been published by DannyS712.

SQL

AخA
 
SELECT cl_from, page.page_title, COUNT(templatelinks.tl_from) AS 'Transclusion count' FROM categorylinks
LEFT JOIN page ON page_id = cl_from
LEFT JOIN templatelinks ON tl_title = page_title
WHERE cl_to = 'Wikipedia_substituted_templates'
AND page_namespace = 10
AND cl_from NOT IN (SELECT cl_from FROM categorylinks WHERE cl_to = 'Wikipedia_templates_to_be_automatically_substituted')
AND tl_namespace = 10
GROUP BY cl_from
ORDER BY COUNT(templatelinks.tl_from) 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...