Toggle navigation
Home
New Query
Recent Queries
Discuss
Database tables
Database names
MediaWiki
Wikibase
Replicas browser and optimizer
Login
History
Fork
Fork of
FSD distribution of Spanish page lengths of a sample (with length > 100)
by
Asoulet
This query is marked as a draft
This query has been published
by
Asoulet
.
Toggle Highlighting
SQL
use dewiki_p; select year, fsd, count(*) as frequency from (select missing_year as year, page_id, substr(max(rev_len),1,1) as fsd from revision, (select page_id, year(max(rev_timestamp)) as last_year from revision, page where rev_page = page_id and page_namespace = 0 and page_id % 100 = 0 and rev_len > 1000 group by page_id) last_revision, (select 2018 as missing_year union select 2017 union select 2016 union select 2015 union select 2014 union select 2013 union select 2012 union select 2011 union select 2010 union select 2009 union select 2008 union select 2007 union select 2006 union select 2005 union select 2004 union select 2003 union select 2002 ) all_years where missing_year > last_year and rev_page = page_id and year(rev_timestamp) = last_year group by missing_year, page_id union select year(a.rev_timestamp) as year, page_id, substr(max(a.rev_len), 1, 1) as fsd from revision a, revision b, revision c, revision d, page where a.rev_page = page_id and page_id % 100 = 0 and a.rev_len > 1000 and a.rev_parent_id = b.rev_id and b.rev_parent_id = c.rev_id and c.rev_parent_id = d.rev_id and abs(cast(a.rev_len as double) - cast(d.rev_len as double)) / cast(d.rev_len as double) < 0.2 and page_namespace = 0 group by year(a.rev_timestamp), page_id) distribution group by year, fsd;
By running queries you agree to the
Cloud Services Terms of Use
and you irrevocably agree to release your SQL under
CC0 License
.
Submit Query
Stop Query
All SQL code is licensed under
CC0 License
.
Checking query status...