title
stringlengths
1
212
description
stringlengths
1
4.39k
query
stringlengths
1
65.5k
extra_info
stringlengths
18
31.6k
wikidb
stringlengths
4
26
Most-used entities on a Wikibase client wiki
Can be used to find those entities that don’t have a label yet, using this query: https://w.wiki/D4o
USE `smnwiki_p`; SELECT `eu_entity_id` FROM `wbc_entity_usage` GROUP BY `eu_entity_id` ORDER BY COUNT(*) DESC LIMIT 1000;
{"runningtime": "0.11", "resultsets": [{"rowcount": 4, "headers": ["Field", "Type", "Null", "Key", "Default", "Extra"]}]}
null
שרי האלפים שרי המאות, בדיקה של יגאל וביקורת
null
use hewiki_p; select user_name, count(page_title) from user join revision_userindex join page join actor on user_id = actor_user and rev_page = page_id and rev_actor = actor_id where page_namespace = 0 and not page_is_redirect and rev_parent_id = 0 and rev_deleted = 0 group by user_name having count(page_title) >= 50 o...
{"runningtime": "4.41", "resultsets": [{"rowcount": 331, "headers": ["actor_name", "files"]}]}
null
Amazon.com links in mainspace
null
SELECT DISTINCT page.page_title, externallinks.el_to FROM externallinks INNER JOIN page ON externallinks.el_from = page.page_id WHERE ((externallinks.el_to LIKE "https://www.amazon.com/_%") OR (externallinks.el_to LIKE "http://www.amazon.com/_%")) AND page.page_namespace = 0
{"runningtime": "37.37", "resultsets": [{"rowcount": 0, "headers": ["log_id", "log_type", "log_action", "user_name", "user_editcount", "user_registration", "log_params"]}, {"rowcount": 0, "headers": ["log_id", "log_type", "log_action", "user_name", "user_editcount", "user_registration", "log_params"]}, {"rowcount": 0, ...
null
Utenti italofoni con più contributi in tutti i progetti
Query to easily make a distribution list for the users having most edits in Wikimedia projects in italic languages, or Italian-language users on multilanguage projects. See also: https://quarry.wmflabs.org/query/23956 https://quarry.wmflabs.org/query/38807 https://quarry.wmflabs.org/query/38639
/* Configure how many edits you want */ SET @min = 250; SET @max = 999; USE itwiki_p; SET @itwikiuserpage = ( SELECT GROUP_CONCAT(TO_BASE64(user_name)) AS u FROM user RIGHT JOIN page -- Check that a local userpage exists as well ON page_namespace = 2 AND REPLACE(page_title, '_', ...
{"runningtime": "0.81", "resultsets": [{"rowcount": 8, "headers": ["linter_cat", "page_namespace", "count(*)"]}, {"rowcount": 3, "headers": ["linter_cat", "count(*)", "count(distinct page_namespace)"]}, {"rowcount": 5, "headers": ["page_namespace", "count(*)", "count(distinct linter_cat)"]}]}
null
It-Wikisources Stats
null
Use itwikisource_p; SELECT U.user_name, count(1) AS edits FROM revision R JOIN user U.user_name ON R.rev_user = U.user_id WHERE R.rev_timestamp >= 20192411000000 AND R.rev_timestamp <= 20191208235959 GROUP BY R.rev_user HAVING edits > 50 ORDER BY edits DESC
{"runningtime": "1.84", "resultsets": [{"rowcount": 345, "headers": ["page_id", "page_title", "ll_title"]}]}
null
ويكيبيديا:إحصاءات العام/2019| تعديلات (بوت)
null
USE arwiki_p; SET @rank=0; SELECT @rank:=@rank+1 AS "المركز", s.* FROM ( SELECT CONCAT("[[مستخدم:",actor_name,"|",actor_name,"]]") AS "المستخدم", COUNT(actor_name) AS "عدد التعديلات" FROM revision INNER JOIN actor on rev_actor = actor_id WHERE rev_timestamp BETWEEN 20200101000000 AND 20201231235959 GROUP BY actor_nam...
{"runningtime": "0.44", "resultsets": [{"rowcount": 4, "headers": ["gender_or_ip", "COUNT(*)"]}]}
null
বাংলা উইকিতে সবচেয়ে বেশী নিবন্ধ সৃষ্টি করা ব্যবহারকারী
১৫-০২-২০১৯ অনুসারে
USE bnwiki_p; SELECT CONCAT("[[ব্যবহারকারী:",user_name,"|",user_name,"]]") AS user_name, COUNT(rev_id) AS মোট_নিবন্ধ FROM user INNER JOIN revision; ON revisions.rev_actor = user.user_id JOIN page ON page.page_id = revision.rev_page WHERE page_is_redirect = 0 AND rev_parent_id = 0 AND page_namespace = 0 AND rev_timestam...
{"resultsets": [{"rowcount": 151, "headers": ["CONCAT('*{{lf|', REPLACE(REPLACE(p.page_title, '\"', '**DOUBLEQUOTE**'), '_', ' '), '}}')"]}], "runningtime": "124.38"}
null
Overlong Stub categories query (6 pages or 5 pages)
null
select cat_title Category, ceil(cat_pages/200) Pages, cat_pages Article from category where cat_title like '%stubs' -- and ceil(cat_pages/200) = 5 and ceil(cat_pages/200) > 5 order by 2 desc
{"resultsets": [{"rowcount": 16, "headers": ["rc_timestamp", "rc_title", "actor_name"]}, {"rowcount": 2, "headers": ["user_name", "ipb_expiry", "comment_text", "Restrictions"]}, {"rowcount": 0, "headers": ["user_name", "gu_locked"]}], "runningtime": "23.52"}
null
2019 successful GA discussions and their contributors
null
use fawiki_p; select page_title, page_random, group_concat(distinct actor_name) as referee from ((page left join revision on rev_page = page_id) left join revision_actor_temp on revactor_rev = rev_id) left join actor on actor_id = revactor_actor and actor_name in ( 'Wikimostafa', '...
{"resultsets": [{"rowcount": 0, "headers": ["page_title"]}], "runningtime": "0.07"}
null
Get all living persons without talk pages
Gets all pages with the category Living persons which don't have a talk page
SELECT page.page_title FROM page INNER JOIN categorylinks ON categorylinks.cl_from = page.page_id WHERE categorylinks.cl_to = "Living_people" and page.page_namespace = "0" and NOT EXISTS (SELECT NULL FROM page p2 WHERE p2.page_namespace = "1" and p2.page_title = page.page_title)
{"resultsets": [{"rowcount": 9, "headers": ["rc_namespace", "rc_title", "days"]}], "runningtime": "19.76"}
null
(Fair) VisualEditor statistics (enwiki)
null
SELECT total, total_ve, 100 * total_ve / total AS ve_pct, total_mob, 100 * total_mob / total AS mob_pct FROM ( SELECT COUNT(*) AS total, SUM(IF(VE.ct_rc_id IS NULL, 0, 1)) AS total_ve, SUM(IF(mob.ct_rc_id IS NULL, 0, 1)) AS total_mob FROM recentchanges LEFT JOIN change_tag AS VE ON VE.ct_rc_id = rc_id AND VE.ct_tag_id ...
{"resultsets": [{"rowcount": 19, "headers": ["files"]}], "runningtime": "69.98"}
enwiki_p
Untranslated redlinks (cswiki)
null
SELECT ref.page_namespace, ref.page_title, pl_title, cs.ips_site_page FROM pagelinks LEFT JOIN page AS missing ON missing.page_title = pl_title AND missing.page_namespace = pl_namespace JOIN wikidatawiki_p.wb_items_per_site AS other ON other.ips_site_id = 'enwiki' AND other.ips_site_page = REPLACE(pl_title, '_', ' ') J...
{"connection_id": 427791008}
cswiki_p
wikidata: number of unpatrolled revisions per day (past 30 days)
null
SELECT SUBSTR(rc_timestamp, 1, 8) AS bucket, COUNT(rc_patrolled) AS cnt FROM recentchanges WHERE rc_patrolled=0 GROUP BY bucket;
{"runningtime": "2.01", "resultsets": [{"headers": ["CONCAT('# [[Template:', tl_title, ']] (', COUNT(*), ' collegamenti)')"], "rowcount": 0}]}
wikidatawiki_p
sysop rights testy
null
-- USE plwiki_p; -- note! only works from about 20060815191823 SELECT log_title, min(log_timestamp), min(log_params), min(user_id) FROM logging l LEFT JOIN user u ON user_name=REPLACE(log_title,'_',' ') WHERE log_type = 'rights' AND log_namespace = '2' AND log_params like '%sysop%' GROUP BY log_title ORDER BY 2 ASC ;
{"resultsets": [{"headers": ["page_namespace", "page_title"], "rowcount": 70}], "runningtime": "0.38"}
plwiki_p
LTA 110.29 zhwikisource
null
use zhwikisource_p; SELECT log_id, log_timestamp, log_title FROM logging LEFT JOIN comment ON log_user_text = rev_user_text WHERE log_type = 'create' AND log_action = "create" AND rev_user_text rlike '118\.161|2001\:b011\:3000' ORDER BY log_timestamp DESC
{"resultsets": [{"headers": ["page_title", "iwl_title"], "rowcount": 0}], "runningtime": "0.05"}
zhwikisource_p
Users by number of created articles
test
USE wuuwiki_p; SELECT a.actor_name, COUNT(*) as count FROM page p, revision rf, actor_user a WHERE rf.rev_page = p.page_id and rf.rev_parent_id = 0 and a.actor_id = rf.rev_actor and p.page_namespace = 0 and p.page_is_redirect = 0 GROUP BY a.actor_name ORDER BY count desc ;
{"resultsets": [{"headers": ["year", "month", "page_namespace", "count"], "rowcount": 21}], "runningtime": "4.16"}
wuuwiki_p
Top missing
Thanks for the coding.
SELECT page_title AS `title`, COUNT(*) AS `languages` FROM `langlinks` LEFT JOIN `page` ON (page_id = ll_from) WHERE page_namespace = '0' AND page_id NOT IN (SELECT ll_from FROM `langlinks` WHERE ll_lang='wuu') GROUP BY page_namespace, page_title HAVING languages > 30 ORDER BY languages DESC
{"resultsets": [{"headers": ["editor", "accepts", "recent_edits"], "rowcount": 1597}], "runningtime": "37.31"}
enwiki_p
Empty pages on plwiki
null
SELECT CONCAT("# [[",page_title,"]]") AS page_title FROM page WHERE page_namespace = 0 AND page_len = 0; SELECT CONCAT("# [[Wikipedia:",page_title,"]]") AS page_title FROM page WHERE page_namespace = 4 AND page_len = 0; SELECT CONCAT("# [[Pliku:",page_title,"]]") AS page_title FROM page WHERE page_namespace = 6 AND p...
{"resultsets": [{"headers": ["year", "month", "page_namespace", "count"], "rowcount": 16}], "runningtime": "0.80"}
plwiki_p
Uncategorized pages on plwiki
null
SELECT CONCAT('# [[:Wikipedia:',page_title,']]') AS page_title FROM page LEFT OUTER JOIN categorylinks ON cl_from = page_id WHERE cl_from IS NULL AND page_namespace = 4 AND page_is_redirect = 0 AND page_title NOT LIKE '%/%'; SELECT CONCAT('# [[:Plik:',page_title,']]') AS page_title FROM page LEFT OUTER JOIN categoryli...
{"resultsets": [{"headers": ["year", "month", "page_namespace", "count"], "rowcount": 0}], "runningtime": "0.06"}
plwiki_p
ব্যবহারকারী ০ সম্পাদনা
null
SELECT user_id, CONCAT("[[User:",user_name,"]]") AS user_name, user_editcount, user_registration FROM user WHERE user_editcount = 0 AND user_registration > 20130101000000 AND user_registration < 20211231235959
{"resultsets": [{"rowcount": 0, "headers": ["user_id", "user_name", "user_real_name", "user_password", "user_newpassword", "user_email", "user_options", "user_touched", "user_token", "user_email_authenticated", "user_email_token", "user_email_token_expires", "user_registration", "user_newpass_time", "user_editcount", "...
bnwiki_p
enwiki inactive admin users
null
SELECT user_name, user_editcount, user_registration, rev_timestamp AS 'Last edit', log_timestamp AS 'Last log', ug1.ug_group AS 'user_group' FROM `user` LEFT JOIN user_groups ug1 ON user_id = ug1.ug_user AND ug1.ug_group IN ('bureaucrat') JOIN actor ON actor_user = user_id JOIN revision_userindex ON rev_id = (SELE...
{"runningtime": "4.72", "resultsets": [{"rowcount": 669, "headers": ["page_title"]}]}
enwiki_p
Query test
null
SELECT CONCAT('# [[', page_title, ']]') FROM page WHERE page_namespace = 0 AND page_is_redirect = 0 AND page_id IN (SELECT tl_from FROM templatelinks WHERE tl_namespace = 10 AND tl_title IN ('Bio')) AND page_id NOT IN (SELECT cl_from FROM categorylinks WHERE cl_to LIKE '%_italian%') AND page_id NOT IN (SELECT ll...
{"connection_id": 1081503483}
itwiki_p
Query test
null
SELECT CONCAT('# [[', page_title, ']]') FROM page WHERE page_namespace = 0 AND page_is_redirect = 0 AND page_id IN (SELECT tl_from FROM templatelinks WHERE tl_namespace = 10 AND tl_title IN ('Bio')) AND page_id NOT IN (SELECT cl_from FROM categorylinks WHERE cl_to LIKE '%_italian%') AND page_id NOT IN (SELECT ll...
{"connection_id": 569549519}
itwiki_p
Query test
null
SELECT CONCAT('# [[', page_title, ']]') FROM page WHERE page_namespace = 0 AND page_is_redirect = 0 AND page_id IN (SELECT tl_from FROM templatelinks WHERE tl_namespace = 10 AND tl_title IN ('Bio')) AND page_id NOT IN (SELECT cl_from FROM categorylinks WHERE cl_to LIKE '%_italian%') AND page_id NOT IN (SELECT ll...
{"runningtime": "0.19", "resultsets": [{"rowcount": 80, "headers": ["pl_from", "pl_namespace", "pl_title", "pl_from_namespace", "page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content...
itwiki_p
Users, actors
Anlage von Benutzerkonten in einem bestimmten Zeitraum
SELECT a.actor_name, count(a.actor_id) AS cnt FROM logging AS l INNER JOIN actor AS a on l.log_actor = a.actor_id WHERE l.log_type = 'newusers' AND l.log_action = 'create' AND l.log_timestamp >'20200101000000' AND l.log_timestamp <'20200102000000' GROUP BY a.actor_name ORDER BY cnt DESC;
{"runningtime": "0.28", "resultsets": [{"rowcount": 0, "headers": ["REGEXP_SUBSTR(el_to, 'Q[0-9]*')", "P18", "CONCAT(\"\\\"\", REPLACE(page_title, \"_\", \" \"), \"\\\"\")"]}]}
dewiki_p
ceb label
Test run
USE wikidatawiki_p; SELECT CONCAT("Q",ips_item_id), "Lceb", CONCAT('"',ips_site_page,'"') FROM wb_items_per_site WHERE ips_site_id='cebwiki' AND NOT EXISTS ( SELECT wbit_item_id FROM wbt_item_terms INNER JOIN wbt_term_in_lang ON wbtl_id = wbit_term_in_lang_id INNER JOIN wbt_text_in_lang ON wbxl_id = wbt...
{"runningtime": "12.99", "resultsets": [{"rowcount": 5980, "headers": ["page_title", "page_is_redirect", "page_len", "pp_value", "pl_title"]}]}
wikidatawiki_p
Number of locks for Spam-only and others
null
USE metawiki_p; SELECT SUBSTR(log_timestamp, 1, 6) AS Month, COUNT(log_id) AS Locks FROM logging JOIN comment ON log_comment_id = comment_id WHERE log_timestamp > '20190000' AND log_action = 'setstatus' AND comment_text = 'Spam-only account: spambot' GROUP BY Month; SELECT SUBSTR(log_timestamp, 1, 6) AS Month, ...
{"runningtime": "526.35", "resultsets": [{"rowcount": 5370, "headers": ["pl_title", "page_id", "rev_id", "lastEdit"]}]}
metawiki_p
English Wiktionary page count by namespace
null
-- simpler but slower query: -- select page_namespace, count(*) - sum(page_is_redirect) as `not redirect`, sum(page_is_redirect) as `redirect` -- from page -- group by page_namespace; SELECT page_namespace, MAX(notredir) as 'not redirect', MAX(redir) as redirect FROM ( SELECT page.page_namespace, IF(p...
{"runningtime": "0.07", "resultsets": [{"rowcount": 1, "headers": ["ss_row_id", "ss_total_edits", "ss_good_articles", "ss_total_pages", "ss_users", "ss_images", "ss_active_users"]}]}
enwiktionary_p
Liczba edycji w plwikisource w 2010 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "7.90", "resultsets": [{"headers": ["ss_total_edits"], "rowcount": 1}, {"headers": ["SUM(user_editcount)"], "rowcount": 1}, {"headers": ["user_id", "user_name", "user_editcount", "user_admin", "user_bot"], "rowcount": 787}]}
plwikisource_p
Liczba edycji w plwikisource w 2011 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "141.25", "resultsets": [{"headers": ["pages_with_disambig_but_not_redir"], "rowcount": 1}, {"headers": ["user_id", "user_name", "user_articles", "user_latestcreation"], "rowcount": 982}]}
plwikisource_p
Liczba edycji w plwikisource w 2012 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "1.75", "resultsets": [{"rowcount": 93, "headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"]}]}
plwikisource_p
Liczba edycji w plwikisource w 2013 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "1.27", "resultsets": [{"rowcount": 324, "headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"]}]}
plwikisource_p
Liczba edycji w plwikisource w 2014 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "0.78", "resultsets": [{"headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"], "rowcount": 0}]}
plwikisource_p
Liczba edycji w plwikisource w 2015 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "0.76", "resultsets": [{"rowcount": 0, "headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"]}]}
plwikisource_p
Liczba edycji w plwikisource w 2016 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "0.83", "resultsets": [{"headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"], "rowcount": 37}]}
plwikisource_p
Liczba edycji w plwikisource w 2017 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "0.77", "resultsets": [{"rowcount": 0, "headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"]}]}
plwikisource_p
Liczba edycji w plwikisource w 2018 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "0.82", "resultsets": [{"headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"], "rowcount": 10}]}
plwikisource_p
Liczba edycji w plwikisource w 2019 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "3.58", "resultsets": [{"rowcount": 1721, "headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"]}]}
plwikisource_p
Liczba edycji w plwikisource w 2007 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "0.79", "resultsets": [{"rowcount": 2, "headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"]}]}
plwikisource_p
Liczba edycji w plwikisource w 2006 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "0.90", "resultsets": [{"rowcount": 57, "headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"]}]}
plwikisource_p
Liczba edycji w plwikisource w 2005 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "0.79", "resultsets": [{"rowcount": 0, "headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"]}]}
plwikisource_p
Liczba edycji w plwikisource w 2009 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "0.82", "resultsets": [{"headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"], "rowcount": 2}]}
plwikisource_p
Liczba edycji w plwikisource w 2008 roku
null
USE plwikisource_p; SET @w:=0; SELECT @w:=@w+1 AS 'Lp',`Użytkownik`,`Link`,`Liczba edycji` FROM (SELECT user_name AS 'Użytkownik', CONCAT('[[Wikiskryba:',user_name,'|',user_name,']]') AS 'Link', COUNT(*) AS 'Liczba edycji' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_...
{"runningtime": "0.81", "resultsets": [{"headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"], "rowcount": 2}]}
plwikisource_p
Most blocks
null
select log_title as 'blocked user', count(*) as times, group_concat(distinct date_format(log_timestamp, '%Y-%m-%d %T') order by log_timestamp separator ',\n') as dates from logging_logindex where log_namespace = 2 and log_type = 'block' and l...
{"runningtime": "0.07", "resultsets": [{"rowcount": 1, "headers": ["REGEXP_SUBSTR('Declining submission: bio - Submission is about a person not yet shown to meet notability guidelines ([[WP:AFCH|AFCH]] 0.9.1)', '\\w*')"]}]}
enwiktionary_p
Protections per day
null
SELECT DATE_FORMAT(log_timestamp, "%Y-%m-%d") AS day, COUNT(*) AS protections FROM logging_userindex JOIN actor ON log_actor = actor_id WHERE actor_name = 'Erutuon' AND log_type = 'protect' AND log_action = 'protect' GROUP BY day DESC;
{"runningtime": "0.14", "resultsets": [{"rowcount": 50, "headers": ["REPLACE(page_title, '_', ' ')"]}]}
enwiktionary_p
Total sizes of Wiktionary namespaces
null
select page_namespace as namespace, sum(page_len) as size from page group by namespace order by size desc;
{"runningtime": "155.74", "resultsets": [{"headers": ["pages", "date"], "rowcount": 387}]}
enwiktionary_p
Most frequently linked-to Wikipedia pages on English Wiktionary
null
SELECT iwl_title AS wikipedia_page, COUNT(iwl_from) AS link_count FROM iwlinks WHERE iwl_prefix IN ("w", "wikipedia") GROUP BY iwl_title ORDER BY link_count DESC LIMIT 5000;
{"runningtime": "0.06", "resultsets": [{"rowcount": 0, "headers": ["CONCAT('# [[{{ns:', page_namespace, '}}:', page_title, ']]')"]}]}
enwiktionary_p
Types of protection by namespace
null
select pr_type as type, pr_level as level, page_namespace as namespace, count(*) as count from page_restrictions join page on page_id = pr_page group by type, level, namespace order by count desc;
{"runningtime": "0.24", "resultsets": [{"rowcount": 1, "headers": ["Anzahl gesamt", "Anzahl Seiten", "Anzahl Weiterleitungen"]}, {"rowcount": 1, "headers": ["Anzahl in Kategorie"]}, {"rowcount": 0, "headers": ["Listen nicht in Kategorie"]}, {"rowcount": 2, "headers": ["Andere Seiten in Kategorie"]}]}
enwiktionary_p
Frequent thanks
Times one person has thanked another on English Wiktionary.
select actor_name as thanker, log_title as thanked, count(*) as times from logging_userindex join actor on actor_id = log_actor where log_type = 'thanks' group by log_actor, log_title having times >= 15 order by times desc;
{"runningtime": "109.56", "resultsets": [{"rowcount": 6, "headers": ["wikitext"]}]}
enwiktionary_p
Most often thanked users on English Wiktionary
Users ranked by the number of times another user has thanked them.
select replace(log_title, '_', ' ') as 'thanked user', count(*) as count from logging where log_type = 'thanks' and log_action = 'thank' group by log_title order by count desc;
{"connection_id": 18669495}
enwiktionary_p
Get all living persons without talk pages
Gets all pages with the category Living persons which don't have a talk page
SELECT CONCAT('আলাপ:',page.page_title) AS page_title FROM page INNER JOIN categorylinks ON categorylinks.cl_from = page.page_id WHERE categorylinks.cl_to = "জীবিত_ব্যক্তি" and page.page_namespace = "0" and NOT EXISTS (SELECT NULL FROM page p2 WHERE p2.page_namespace = "1" and p2.page_title = page.page_title)
{"runningtime": "1.87", "resultsets": [{"rowcount": 53, "headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"]}]}
bnwiki_p
Commons:Pages with local object heading and missing SDC heading
null
SELECT concat("M",page_id) AS MID, 'P1259', REGEXP_REPLACE(el_to,'[^&]*&params=([^_]+)_N_([^_]*).*','@\\1/\\2') AS coordinates, 'P7787', concat(replace(REGEXP_SUBSTR(el_to, '_heading:([^_&]*)'),'_heading:',''),'U28390') as heading, '/* extracted from {{Object_location}} template */' #el_to FROM pa...
{"runningtime": "0.09", "resultsets": [{"rowcount": 10, "headers": ["ar_id", "ar_namespace", "ar_title", "ar_text", "ar_comment_id", "ar_actor", "ar_timestamp", "ar_minor_edit", "ar_flags", "ar_rev_id", "ar_deleted", "ar_len", "ar_page_id", "ar_parent_id", "ar_sha1"]}]}
commonswiki_p
KSA new articles by months test 14
null
use arwiki_p; SELECT left(t4.rev_timestamp,8) as Menesis, count(left(t4.rev_timestamp,8)) as Raksti FROM revision AS t4 JOIN page article ON article.page_id = rev_page AND article.page_namespace = 0 INNER JOIN page talk ON talk.page_title = article.page_title AND talk.page_namespace = 1 INNER JOIN category...
{"runningtime": "0.08", "resultsets": [{"rowcount": 10, "headers": ["pi_property_id", "pi_type", "pi_info"]}]}
arwiki
Wikidata:list of properties labels (Bangla) updated
null
SELECT CURRENT_DATE; SELECT CONCAT('P', term_entity_id) as P, term_text as description from wb_terms WHERE term_entity_type = 'property' AND term_language = 'bn' and term_type = 'label' ORDER bY term_entity_id desc;
{"runningtime": "8.40", "resultsets": [{"headers": ["page_title", "pp_value", "cl_to", "cl_sortkey"], "rowcount": 1000}]}
wikidatawiki_p
Voci più richieste con # link in ingresso >= 100
null
SELECT pl_title, linkcounter FROM (SELECT pl_title , COUNT(*) as linkcounter , pl_namespace FROM pagelinks WHERE pl_from_namespace=0 AND pl_namespace=0 GROUP BY pl_title, pl_namespace HAVING COUNT(*)>99) AS pl LEFT JOIN page ON (pl_title=page_title AND page_namespace= pl_namespace) WHERE ...
{"runningtime": "1376.70", "resultsets": [{"headers": ["tl_title"], "rowcount": 49}]}
itwiki_p
Voci più richieste con # link in ingresso tra 75 e 99
null
SELECT pl_title, linkcounter FROM (SELECT pl_title , COUNT(*) as linkcounter , pl_namespace FROM pagelinks WHERE pl_from_namespace=0 AND pl_namespace=0 GROUP BY pl_title, pl_namespace HAVING COUNT(*)>=75 AND COUNT(*)<=99) AS pl LEFT JOIN page ON (pl_title=page_title AND page_namespace= pl...
{"runningtime": "15.05", "resultsets": [{"rowcount": 91, "headers": ["actor_name", "cnt"]}]}
itwiki_p
Voci più richieste con # link in ingresso tra 60 e 74
null
USE itwiki_p; SELECT pl_title, linkcounter FROM (SELECT pl_title , COUNT(*) as linkcounter , pl_namespace FROM pagelinks WHERE pl_from_namespace=0 AND pl_namespace=0 GROUP BY pl_title, pl_namespace HAVING COUNT(*)>=60 AND COUNT(*)<=74) AS pl LEFT JOIN page ON (pl_title=page_title AND page...
{"runningtime": "8.53", "resultsets": [{"rowcount": 237, "headers": ["actor_user", "actor_name", "cnt"]}]}
itwiki_p
Wonderfool editcounts and block dates
null
SET @wonderfool_page = ( SELECT page_id FROM page WHERE page_namespace = 2 # User AND page_title = 'AryamanA/Wonderfool' ); SELECT user_name AS name, user_editcount AS 'edit count', lb_date as 'block date' FROM (SELECT pl_title AS wonderfool_name FROM pagelinks WHERE pl_from = @wonde...
{"runningtime": "29.58", "resultsets": [{"rowcount": 101, "headers": ["Tables_in_bnwiki_p"]}, {"rowcount": 18823, "headers": ["page_title"]}]}
enwiktionary_p
মোট সম্পাদনার সংখ্যা
০২-০৯-২০১৮
USE wikidatawiki_p; SET @counter:=0; SELECT CONCAT("}}{{subst:সসংঅউতা|",@counter:=@counter+1,"") AS rank, CONCAT("|",user_name,"|") AS user_name, user_editcount FROM user WHERE user_id NOT IN (SELECT ug_user FROM user_groups WHERE ug_group = 'bot') AND user_name NOT RLIKE "(.*)([Bb][Oo][Tt])(.*)" ORDER BY user_editcoun...
{"runningtime": "0.56", "resultsets": [{"rowcount": 32, "headers": ["user", "img_count"]}]}
wikidatawiki_p
Number of edits in ltwikisource
null
USE ltwikisource_p; SET @w:=0; SET @s:=0; SELECT @w:=@w+1 AS 'Pos.',`Number of edits`,`User`,@s:=@s+`Number of edits` AS 'Cumulatively' FROM (SELECT user_name AS 'User', COUNT(*) AS 'Number of edits' FROM actor JOIN revision ON rev_actor=actor_id JOIN user ON actor_user=user_id JOIN page ON rev_page=page_id WHERE ...
{"runningtime": "28.17", "resultsets": [{"headers": ["page_title"], "rowcount": 2}]}
ltwikisource_p
Testquarries
Only testing
SELECT page2.page_id, page2.page_title, page2.page_namespace FROM page as page2 WHERE page2.page_namespace=0 AND LENGTH(page2.page_title)>=12 AND SUBSTRING('12_Monkeys_(Fersehserie)',1,12)=SUBSTRING(page2.page_title,1,12)
{"runningtime": "0.86", "resultsets": [{"headers": ["actor_name", "countt"], "rowcount": 28}]}
dewiki_p
عدد المقالات
null
USE arwiki_p; SELECT COUNT(*) AS "عدد المقالات" FROM revision r join page p on p.page_id=r.rev_page WHERE p.page_namespace=0 and p.page_is_redirect=0 and r.rev_parent_id=0 ORDER BY COUNT(*) DESC LIMIT 1;
{"resultsets": [{"headers": ["COUNT(1)"], "rowcount": 1}], "runningtime": "57.63"}
arwiki
Ownerless user and user talk pages at hywiki
User and user talk pages and subpages where the base page name doesn't look like an IP address and isn't a username.
use hywiki_p; select id, ns, title, concat(if(ns = 2, "User", "User_talk"), ":", title) as full_title, content_model, len, is_redirect from (select page_id as id, page_namespace as ns, page_title as title, page_content_model as content_model, page_len as...
{"resultsets": [{"headers": ["EXTRACT(DAY_HOUR FROM rc_timestamp)"], "rowcount": 5}], "runningtime": "1.07"}
hywiki
find pagelinks title LIKE '%ttp%'
null
#USE commonswiki_p; SELECT CONCAT ("Category_talk:",page_title,"") #LEFT JOIN page as page ON page_id=cat_id FROM page AS page WHERE page_namespace =15 #AND page_title LIKE "K%" #cat_title LIKE '%by_quantity%' #AND page_len >0 #AND cat_title NOT LIKE "Images_from_the_Geograph_British_Isles_project_needing_categories...
{"resultsets": [{"headers": ["af_enabled", "COUNT(*)"], "rowcount": 2}], "runningtime": "0.08"}
enwiki_p
Automatic user promotion on pl.wiki 1
null
SET @editComments = 50; SET @uniqueContentPages = 14; SET @totalContentEdits = 300; SET @reviewedEdits = 200; SET @revertedEditsRatio = 0.03; SET @usergroup="editor"; SET @userregistratioage=60; SET @unique_days_with_edits=45; -- newver blocked is always true -- newer demoted is always true SELECT * FROM ( SELECT tt.*...
{"resultsets": [{"headers": ["tl_from", "tl_namespace", "tl_title", "tl_from_namespace"], "rowcount": 50}], "runningtime": "0.64"}
plwiki_p
Automatic user promotion on pl.wiki 2
null
SET @editComments = 20; SET @uniqueContentPages = 8; SET @totalContentEdits = 150; SET @reviewedEdits = 50; SET @revertedEditsRatio = 1; SET @usergroup="autoreview"; SET @userregistratioage=30; SET @unique_days_with_edits=21; -- newver blocked is always true -- newer demoted is always true SELECT * FROM ( SELECT tt.*,...
{"resultsets": [{"headers": ["tl_from", "tl_namespace", "tl_title", "tl_from_namespace"], "rowcount": 50}], "runningtime": "0.15"}
plwiki_p
ويكيبيديا:إحصاءات العام/2019| تعديلات
null
USE arwiki_p; SET @rank=0; SELECT @rank:=@rank+1 AS "المركز", s.* FROM ( SELECT CONCAT("[[مستخدم:",actor_name,"|",actor_name,"]]") AS "المستخدم", COUNT(actor_name) AS "عدد التعديلات" FROM revision INNER JOIN actor on rev_actor = actor_id WHERE rev_timestamp BETWEEN 20210101000000 AND 20211231235959 AND actor_name IN ...
{"resultsets": [{"headers": ["num_transclusions"], "rowcount": 100}], "runningtime": "1.18"}
arwiki_p
KSA new articles by year
null
use arwiki_p; SELECT left(t4.rev_timestamp,4) as Menesis, count(left(t4.rev_timestamp,4)) as Raksti FROM revision AS t4 JOIN page article ON article.page_id = rev_page AND article.page_namespace = 0 INNER JOIN page talk ON talk.page_title = article.page_title AND talk.page_namespace = 1 INNER JOIN category...
{"resultsets": [{"headers": ["rc_patrolled", "count"], "rowcount": 4}, {"headers": ["user", "unpatrolled"], "rowcount": 10}, {"headers": ["day", "unpatrolled", "manually patrolled", "autopatrolled", "total"], "rowcount": 31}, {"headers": ["rc_namespace", "unpatrolled"], "rowcount": 1}, {"headers": ["rc_namespace", "rc_...
arwiki
Recently touched pages in MediaWiki-namespace
null
SELECT page_id, page_title, page_latest, page_touched, page_links_updated FROM page WHERE page_namespace=8 ORDER BY page_touched DESC LIMIT 10;
{"resultsets": [{"headers": ["log_title", "COUNT(log_id)"], "rowcount": 7458}], "runningtime": "13.74"}
enwiki_p
?country = ?citizenship
null
DESCRIBE wb_property_info; SELECT CONCAT("Q",ips_item_id) AS qid from wb_items_per_site group by qid Limit 10
{"resultsets": [{"headers": ["log_id", "log_timestamp", "user", "log_title", "log_params", "summary"], "rowcount": 100}], "runningtime": "13.20"}
wikidatawiki_p
মোট সম্পাদনার সংখ্যা
০২-০৯-২০১৮
USE bnwiki_p; SET @counter:=0; SELECT CONCAT("}}{{subst:সসংঅউতা|",@counter:=@counter+1,"") AS rank, CONCAT("|",user_name,"|") AS user_name, user_editcount FROM user WHERE user_id NOT IN (SELECT ug_user FROM user_groups WHERE ug_group = 'bot') AND user_name NOT RLIKE "(.*)([Bb][Oo][Tt])(.*)" ORDER BY user_editcount DESC...
{"resultsets": [{"headers": ["cat"], "rowcount": 1}], "runningtime": "0.52"}
bnwiki_p
Flughafen
null
USE dewiki_p; SELECT COUNT(*) as cnt, CONCAT('[[', REPLACE(pl_title, '_', ' '), ']]') as title FROM pagelinks LEFT JOIN page ON pl_title = page_title AND pl_namespace = page_namespace WHERE page_id IS NULL AND pl_namespace = 0 AND pl_from_namespace = 0 AND (pl_title LIKE "%Flughafen%" COLLATE utf8_general_c...
{"resultsets": [{"headers": ["editor", "accepts", "recent_edits"], "rowcount": 1709}], "runningtime": "14.72"}
dewiki_p
Articles by lint errors except for Obsolete HTML tags
০২-০৮-২০১৮
select page_title , count(*) as page_count , sum(case when linter_params like '%"name":"center"%' then 1 end) as tag_center , sum(case when linter_params like '%"name":"small"%' then 1 end) as tag_small , sum(case when linter_params like '%"name":"span"%' then 1 end) as tag_span , sum(case when linter_params like '%"na...
{"resultsets": [{"headers": ["pp_value", "pl_title", "rd_title"], "rowcount": 1179}], "runningtime": "1.91"}
bnwiki_p
Wikidata:Missing Commons creator templates on Wikidata
Get a list of Qid's and name of Commons creator templates based on https://commons.wikimedia.org/wiki/Category:Creator_templates_with_Wikidata_link:_item_missing_P1472 so we can add it using quickstatements.
SELECT iwl_title, 'P1472', CONCAT("\"", REPLACE(page_title, "_", " "), "\"") FROM categorylinks JOIN page ON cl_from=page_id AND page_namespace=100 AND page_is_redirect=0 JOIN iwlinks ON cl_from=iwl_from AND page_id=cl_from AND iwl_prefix='wikidata' AND iwl_title LIKE 'Q%' WHERE cl_to='Creator_templates_with_Wikidata_l...
{"resultsets": [{"headers": ["CONCAT(\"# [[:Categoria:\", page_title, \"]]\")"], "rowcount": 0}], "runningtime": "0.05"}
commonswiki_p
Wikidata:Pages that don't have bpy label at Wikidata
করতে হবে
SELECT CONCAT("Q",ips_item_id), "Lbpy", CONCAT('"',ips_site_page,'"') FROM wb_items_per_site WHERE ips_site_id='bpywiki' AND NOT EXISTS ( SELECT wbit_item_id FROM wbt_item_terms INNER JOIN wbt_term_in_lang ON wbtl_id = wbit_term_in_lang_id INNER JOIN wbt_text_in_lang ON wbxl_id = wbtl_text_in_lang_id ...
{"resultsets": [{"headers": ["page_title", "edits"], "rowcount": 707}], "runningtime": "4.81"}
wikidatawiki_p
Wikidata:Pages that don't have Hindi label at Wikidata
করতে হবে
SELECT CONCAT("Q",ips_item_id), "Lhi", CONCAT('"',ips_site_page,'"') FROM wb_items_per_site WHERE ips_site_id='hiwiki' AND NOT EXISTS ( SELECT wbit_item_id FROM wbt_item_terms INNER JOIN wbt_term_in_lang ON wbtl_id = wbit_term_in_lang_id INNER JOIN wbt_text_in_lang ON wbxl_id = wbtl_text_in_lang_id WH...
{"resultsets": [], "runningtime": "0.02"}
wikidatawiki_p
Wikidata:Capture QuickStatement external links of {{Artwork}} templates
null
SELECT concat(REPLACE(REPLACE(REPLACE(el_to, 'https://tools.wmflabs.org/quickstatements/index_old.html#v1=',''),'%09','|'),'%0A','|'),'S4656|\'"https://commons.wikimedia.org/wiki/File:',page_title,'"') FROM externallinks JOIN page ON page_id = el_from JOIN categorylinks ON cl_from = page_id WHERE page_namespace = ...
{"resultsets": [{"headers": ["CONCAT(\"Q\",ips_item_id)", "Lar", "CONCAT('\"',ips_site_page,'\"')"], "rowcount": 491}], "runningtime": "557.30"}
commonswiki_p
Wikidata:Redirects in bnwiki connected with Wikidata
null
SELECT page_namespace, page_title AS page, pp_value AS item FROM (SELECT * FROM page WHERE page_is_redirect = 1) AS page JOIN (SELECT * FROM page_props WHERE pp_propname = 'wikibase_item') AS props ON pp_page = page_id ORDER BY page_title, page_namespace;
{"resultsets": [{"headers": ["actor_name", "c"], "rowcount": 156}], "runningtime": "0.38"}
bnwiki_p
Wikidata:Items have Bangla articles sitelink without any statements
null
SELECT * FROM wb_items_per_site,page_props,page WHERE ips_site_id IN ('bnwiki') AND page_namespace=0 AND ips_item_id=substr(page_title,2)*1 AND page_id=pp_page AND pp_propname='wb-claims' AND pp_sortkey=0 LIMIT 5000
{"resultsets": [{"headers": ["actor_name", "c"], "rowcount": 97}], "runningtime": "0.27"}
wikidatawiki_p
Wikidata:Disambiguations with properties
null
SELECT page_title, COUNT(p.pl_title) AS number FROM pagelinks AS d JOIN pagelinks AS p ON d.pl_from = p.pl_from JOIN page ON page_id = d.pl_from WHERE d.pl_title = 'Q4167410' AND d.pl_namespace = 0 AND p.pl_namespace = 120 AND p.pl_title NOT IN ('P31', 'P143', 'P248', 'P373', 'P460', 'P813', 'P1013', 'P1889', 'P3096', ...
{"resultsets": [{"headers": ["ss_total_edits"], "rowcount": 1}, {"headers": ["SUM(user_editcount)"], "rowcount": 1}, {"headers": ["user_id", "user_name", "user_editcount", "user_admin", "user_bot"], "rowcount": 804}], "runningtime": "6.59"}
wikidatawiki_p
Wikidata:Pages that don't have Bengali label at Wikidata
null
SELECT CONCAT("Q",ips_item_id), "Lbn", CONCAT('"',ips_site_page,'"') FROM wb_items_per_site WHERE ips_site_id='bnwiki' AND NOT EXISTS ( SELECT wbit_item_id FROM wbt_item_terms INNER JOIN wbt_term_in_lang ON wbtl_id = wbit_term_in_lang_id INNER JOIN wbt_text_in_lang ON wbxl_id = wbtl_text_in_lang_id WH...
{"resultsets": [{"headers": ["concat(\"\u09aa\u09be\u09a4\u09be:\", page_title)", "page_len"], "rowcount": 10331}], "runningtime": "14.18"}
wikidatawiki_p
All categories with Wikidata link that aren't using Wikidata Infobox or Taxonavigation
null
SELECT DISTINCT pp.pp_value, p1.page_title, tl.tl_namespace, tl.tl_title FROM categorylinks AS c1 JOIN page AS p1 ON c1.cl_from=p1.page_id AND p1.page_namespace=14 AND p1.page_is_redirect=0 JOIN page_props AS pp ON pp.pp_page = p1.page_id AND pp.pp_propname = 'wikibase_item' LEFT JOIN templatelinks AS tl ON tl.tl_from ...
{"resultsets": [{"headers": ["concat(\"\u09aa\u09be\u09a4\u09be:\", page_title)", "page_len"], "rowcount": 10331}], "runningtime": "12.86"}
commonswiki_p
Pages that don't have Arabic label at Wikidata
করতে হবে
SELECT CONCAT("Q",ips_item_id), "Lar", CONCAT('"',ips_site_page,'"') FROM wb_items_per_site WHERE ips_site_id='arwiki' AND NOT EXISTS ( SELECT wbit_item_id FROM wbt_item_terms INNER JOIN wbt_term_in_lang ON wbtl_id = wbit_term_in_lang_id INNER JOIN wbt_text_in_lang ON wbxl_id = wbtl_text_in_lang_id WH...
{"resultsets": [{"headers": ["actor_id", "actor_user", "actor_name"], "rowcount": 0}], "runningtime": "0.05"}
wikidatawiki_p
RestrictedEnwikiPages
This is now deprecated, as the page_restrictions column is unused. Use the new page_restrictions table.
SELECT page_id, page_title, page_restrictions FROM page WHERE page_namespace = 0 AND page_restrictions <> "" LIMIT 100;
{"resultsets": [{"headers": ["actor_name", "num"], "rowcount": 620}], "runningtime": "43.88"}
enwiki_p
Main pl.wiki query 2
null
SELECT CONCAT("# [[",page_title,"]]") AS page_title FROM page WHERE page_namespace = 0 AND page_len = 0; SELECT CONCAT("# [[Wikipedia:",page_title,"]]") AS page_title FROM page WHERE page_namespace = 4 AND page_len = 0 AND page_title NOT LIKE '%sprawozdanie%'; SELECT CONCAT("# [[Plik:",page_title,"]]") AS page_title ...
{"resultsets": [{"headers": ["page_title"], "rowcount": 2609}], "runningtime": "51.01"}
plwiki_p
admins with the most user-rights
null
SELECT DISTINCT user_name, (SELECT COUNT(*) FROM user_groups WHERE user_id = ug_user) FROM user_groups JOIN user ON user_id = ug_user WHERE ug_group NOT IN ('bot') AND ug_group = 'sysop'
{"resultsets": [{"headers": ["distanz_ungefaehr", "gt_lat", "gt_lon", "gt_page_id", "gt_name", "ns", "title", "gt_country", "gt_region"], "rowcount": 500}, {"headers": ["distanz_ungefaehr", "gt_lat", "gt_lon", "gt_page_id", "gt_name", "ns", "title", "gt_country", "gt_region"], "rowcount": 140}], "runningtime": "2.65"}
enwiki
Link rossi
null
SELECT DISTINCT CONCAT('#[[', REPLACE(pl_title,'_',' '), ']]') FROM pagelinks WHERE pl_namespace = 0 AND pl_from_namespace = 0 /*AND pl_title > '1'*/ AND NOT EXISTS ( SELECT NULL FROM page WHERE page_namespace = 0 AND page_title = pl_title ) LIMIT 10000;
{"resultsets": [{"headers": ["log_id", "log_type", "log_action", "log_timestamp", "log_actor", "log_namespace", "log_title", "log_comment_id", "log_params", "log_deleted", "log_page"], "rowcount": 10}], "runningtime": "0.08"}
itwiki_p
(empty)
null
null
{"resultsets": [{"headers": ["page_title"], "rowcount": 896}], "runningtime": "13.31"}
nlwiki
unused images
download data as tsv and copypaste to wiki inside the gallery-tags
select concat(p1.page_title, "|", "[[:file:", p1.page_title, "|", replace(p1.page_title, "_", " "), "]]") as t from image, page as p1 LEFT JOIN imagelinks as il1 ON p1.page_title=il1.il_to AND il_from_namespace=0 where img_name=p1.page_title and p1.page_namespace=6 and il_to IS NULL order by im...
{"resultsets": [{"headers": ["rc_title", "actor_name", "comment_text", "time"], "rowcount": 4}], "runningtime": "299.19"}
fiwiki_p
Links to THOMAS
null
SELECT DISTINCT page.page_title, externallinks.el_to FROM externallinks INNER JOIN page ON externallinks.el_from = page.page_id WHERE externallinks.el_to LIKE "http://thomas.loc.gov/%" AND page.page_namespace = 0
{"resultsets": [{"headers": ["date", "active_admin_count"], "rowcount": 29}], "runningtime": "0.89"}
enwiki_p
Overlong Stub categories query (6 pages or 5 pages)
null
select cat_title Category, ceil(cat_pages/200) Pages, cat_pages Article from category where cat_title like '%stubs' -- and ceil(cat_pages/200) = 5 and ceil(cat_pages/200) = 5 order by 2 desc
{"resultsets": [{"headers": ["page_title", "cl_to"], "rowcount": 1}], "runningtime": "0.06"}
en_wiki_p
find pages transcluding {{Translation_table}} template
null
USE commonswiki_p; select concat("Category:",page_title) as pagename from page join templatelinks on page_id = tl_from and tl_namespace = 10 AND tl_title = "Translation_table" where page_namespace = 14
{"resultsets": [{"headers": ["actor_name", "pagename", "HEX(page_title)", "date"], "rowcount": 5669}], "runningtime": "8.50"}
commonswiki_p
Use of shortdesc helper
null
select count(*) from recentchanges, comment where rc_timestamp > 20220520120000 and rc_comment_id = comment_id and comment_text like '%Shortdesc helper%' order by count(*) desc;
{"resultsets": [{"headers": ["page_title"], "rowcount": 0}], "runningtime": "0.08"}
enwiki_p
Editors by experience 60-65k
With a little help from [[User talk:Cryptic#A Little help with a query]] circa 7 Feb 2020. Editors who are extended confirmed, are not new page patrollers or sysops, have not been blocked in the last year, have at least 500 edits in the last 6 months, 50 edits in the last 2 months, created at least 2 non-stub pages, ha...
SELECT user_id, user_name, user_editcount, user_registration FROM `user` JOIN actor_user on actor_user=user_id WHERE user_editcount BETWEEN 60000 AND 65000 AND user_registration < '20190228000000' AND EXISTS (SELECT 1 FROM user_groups WHERE user_id=ug_user AND ug_group = 'extendedconfirmed') AND NOT EXISTS (SELEC...
{"resultsets": [{"headers": ["rev_id", "rev_page", "rev_comment_id", "rev_actor", "rev_timestamp", "rev_minor_edit", "rev_deleted", "rev_len", "rev_parent_id", "rev_sha1"], "rowcount": 1}], "runningtime": "0.05"}
enwiki_p
Editors by experience 50-55k
With a little help from [[User talk:Cryptic#A Little help with a query]] circa 7 Feb 2020. Editors who are extended confirmed, are not new page patrollers or sysops, have not been blocked in the last year, have at least 500 edits in the last 6 months, 50 edits in the last 2 months, created at least 2 non-stub pages, ha...
SELECT user_id, user_name, user_editcount, user_registration FROM `user` JOIN actor_user on actor_user=user_id WHERE user_editcount BETWEEN 50000 AND 55000 AND user_registration < '20190228000000' AND EXISTS (SELECT 1 FROM user_groups WHERE user_id=ug_user AND ug_group = 'extendedconfirmed') AND NOT EXISTS (SELEC...
{"resultsets": [{"headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang", "rev_id", "rev_page", "rev_comment_id", "rev_actor", "rev_timestamp", "rev_mi...
enwiki_p
Editors by experience 45-50k
With a little help from [[User talk:Cryptic#A Little help with a query]] circa 7 Feb 2020. Editors who are extended confirmed, are not new page patrollers or sysops, have not been blocked in the last year, have at least 500 edits in the last 6 months, 50 edits in the last 2 months, created at least 2 non-stub pages, ha...
SELECT user_id, user_name, user_editcount, user_registration FROM `user` JOIN actor_user on actor_user=user_id WHERE user_editcount BETWEEN 45000 AND 50000 AND user_registration < '20190228000000' AND EXISTS (SELECT 1 FROM user_groups WHERE user_id=ug_user AND ug_group = 'extendedconfirmed') AND NOT EXISTS (SELEC...
{"resultsets": [{"headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang", "rev_id", "rev_page", "rev_comment_id", "rev_actor", "rev_timestamp", "rev_mi...
enwiki_p
Editors by experience 40-45k
With a little help from [[User talk:Cryptic#A Little help with a query]] circa 7 Feb 2020. Editors who are extended confirmed, are not new page patrollers or sysops, have not been blocked in the last year, have at least 500 edits in the last 6 months, 50 edits in the last 2 months, created at least 2 non-stub pages, ha...
SELECT user_id, user_name, user_editcount, user_registration FROM `user` JOIN actor_user on actor_user=user_id WHERE user_editcount BETWEEN 40000 AND 45000 AND user_registration < '20190228000000' AND EXISTS (SELECT 1 FROM user_groups WHERE user_id=ug_user AND ug_group = 'extendedconfirmed') AND NOT EXISTS (SELEC...
{"resultsets": [{"headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang", "rev_id", "rev_page", "rev_comment_id", "rev_actor", "rev_timestamp", "rev_mi...
enwiki_p
Editors by experience 35-40k
With a little help from [[User talk:Cryptic#A Little help with a query]] circa 7 Feb 2020. Editors who are extended confirmed, are not new page patrollers or sysops, have not been blocked in the last year, have at least 500 edits in the last 6 months, 50 edits in the last 2 months, created at least 2 non-stub pages, ha...
SELECT user_id, user_name, user_editcount, user_registration FROM `user` JOIN actor_user on actor_user=user_id WHERE user_editcount BETWEEN 35000 AND 40000 AND user_registration < '20190228000000' AND EXISTS (SELECT 1 FROM user_groups WHERE user_id=ug_user AND ug_group = 'extendedconfirmed') AND NOT EXISTS (SELEC...
{"resultsets": [{"headers": ["page_namespace", "page_id", "page_title", "page_is_redirect", "page_len"], "rowcount": 0}], "runningtime": "61.34"}
enwiki_p
Editors by experience 30-35k
With a little help from [[User talk:Cryptic#A Little help with a query]] circa 7 Feb 2020. Editors who are extended confirmed, are not new page patrollers or sysops, have not been blocked in the last year, have at least 500 edits in the last 6 months, 50 edits in the last 2 months, created at least 2 non-stub pages, ha...
SELECT user_id, user_name, user_editcount, user_registration FROM `user` JOIN actor_user on actor_user=user_id WHERE user_editcount BETWEEN 30000 AND 35000 AND user_registration < '20190228000000' AND EXISTS (SELECT 1 FROM user_groups WHERE user_id=ug_user AND ug_group = 'extendedconfirmed') AND NOT EXISTS (SELEC...
{"resultsets": [{"headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"], "rowcount": 0}], "runningtime": "0.14"}
enwiki_p
Editors by experience 25-30k
With a little help from [[User talk:Cryptic#A Little help with a query]] circa 7 Feb 2020. Editors who are extended confirmed, are not new page patrollers or sysops, have not been blocked in the last year, have at least 500 edits in the last 6 months, 50 edits in the last 2 months, created at least 2 non-stub pages, ha...
SELECT user_id, user_name, user_editcount, user_registration FROM `user` JOIN actor_user on actor_user=user_id WHERE user_editcount BETWEEN 25000 AND 30000 AND user_registration < '20190228000000' AND EXISTS (SELECT 1 FROM user_groups WHERE user_id=ug_user AND ug_group = 'extendedconfirmed') AND NOT EXISTS (SELEC...
{"resultsets": [{"headers": ["page_id", "page_namespace", "page_title", "page_restrictions", "page_is_redirect", "page_is_new", "page_random", "page_touched", "page_links_updated", "page_latest", "page_len", "page_content_model", "page_lang"], "rowcount": 0}], "runningtime": "0.09"}
enwiki_p