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

SQL

x
 
SET @yr='1914_births';
WITH results AS
(SELECT COUNT(rev_page) AS pages, actor_name AS creator
 FROM actor_revision
 JOIN revision ON rev_actor = actor_id
 WHERE rev_id IN
  (SELECT MIN(rev_id)
   FROM revision
   WHERE rev_page IN
    (SELECT DISTINCT birth.cl_from
     FROM categorylinks AS birth
     JOIN categorylinks AS stub ON stub.cl_from = birth.cl_from
     WHERE birth.cl_to = @yr
       AND stub.cl_to = 'All_stub_articles')
   GROUP BY rev_page)
 GROUP BY actor_name)
SELECT SUM(pages) AS pages, 'TOTAL' AS creator FROM results
UNION
SELECT * FROM results ORDER BY pages DESC, creator ASC;
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...