SQL
AخA
SELECT
count(*) ll_count,
CONCAT("[[:sl:",page.page_title,"]]") title_simple,
(select CONCAT("[[:lt:",ll_title,"]]") from langlinks where ll_from = page.page_id and ll_lang = 'lt') title_lt
FROM (SELECT tmpl.page_id, tmpl.page_title, tmpl.page_namespace FROM pagelinks
JOIN page AS drut ON drut.page_id = pl_from
JOIN page AS tmpl ON tmpl.page_namespace = pl_namespace AND tmpl.page_title = pl_title
WHERE drut.page_namespace = 4 AND drut.page_title = 'Artikel,_die_es_in_allen_Wikipedias_geben_sollte'
AND tmpl.page_namespace = 0
) as page, langlinks
WHERE
ll_from = page.page_id and
page.page_namespace = 0
GROUP BY
page_id
ORDER BY
ll_count desc, page_title
LIMIT
2050; -- top N
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.