Fork of
zhwp: C-Class articles
by Xiplus
This query is marked as a draft
This query has been published
by Xiplus.
SQL
x
USE zhwiki_p;
SELECT DISTINCT cl_from, page_title, page_len
FROM categorylinks
LEFT JOIN page ON cl_from = page_id
WHERE cl_to IN (
SELECT page_title
FROM categorylinks
LEFT JOIN page ON cl_from = page_id
WHERE cl_to = '初级条目'
)
AND cl_type = 'page';
SELECT SUM(page_len)
FROM categorylinks
LEFT JOIN page ON cl_from = page_id
WHERE cl_to IN (
SELECT page_title
FROM categorylinks
LEFT JOIN page ON cl_from = page_id
WHERE cl_to = '初级条目'
)
AND cl_type = 'page';
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.