SQL
x
set @actor1="Chaduvari";
select actor_id into @actor from actor where actor_name=@actor1;
select COUNT(rev_actor) into @all_edits FROM revision
WHERE rev_actor = @actor;
select COUNT(rev_actor) into @article_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=0;
select COUNT(rev_actor) into @talk_page_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=1;
select COUNT(rev_actor) into @user_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=2;
select COUNT(rev_actor) into @user_talk_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=3;
select COUNT(rev_actor) into @wikipedia_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=4;
select COUNT(rev_actor) into @wikipedia_talk_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=5;
select COUNT(rev_actor) into @mediawiki_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=8;
select COUNT(rev_actor) into @mediawiki_talk_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=9;
select COUNT(rev_actor) into @template_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=10;
select COUNT(rev_actor) into @template_talk_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=11;
select COUNT(rev_actor) into @category_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=14;
select COUNT(rev_actor) into @category_talk_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=15;
select COUNT(rev_actor) into @help_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=12;
select COUNT(rev_actor) into @help_talk_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=13;
select COUNT(rev_actor) into @file_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=6;
select COUNT(rev_actor) into @file_talk_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=7;
select COUNT(rev_actor) into @module_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=828;
select COUNT(rev_actor) into @module_talk_edits FROM revision,page WHERE rev_actor = @actor
and page_id=rev_page and page_namespace=829;
set @other_edits=@all_edits-(@module_edits+@module_talk_edits+@file_edits+@file_talk_edits+@article_edits+@talk_page_edits+@user_edits+@user_talk_edits+@wikipedia_edits+@wikipedia_talk_edits+@mediawiki_edits+@mediawiki_talk_edits+@template_edits+@template_talk_edits+@category_edits+@category_talk_edits+@help_edits+@help_talk_edits);
Select @actor1,@all_edits,@article_edits,@talk_page_edits,@user_edits,@user_talk_edits,@wikipedia_edits,@wikipedia_talk_edits,@mediawiki_edits,@mediawiki_talk_edits,@template_edits,@template_talk_edits,@category_edits,@category_talk_edits,@help_edits,@help_talk_edits,@file_edits,@file_talk_edits,@module_edits,@module_talk_edits,@other_edits;
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.