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

SQL

AخA
 
use arwiki_p;
select user_name, (select count(*) from logging where log_user = user_id and log_type = "rights" and 
                  log_params like '%5::newgroups%"bot"%') as "+بوت",
                  (select count(*) from logging where log_user = user_id and log_type = "rights" and 
                  log_params like '%5::newgroups%"sysop"%') as "+إداري",
                  (select count(*) from logging where log_user = user_id and log_type = "rights" and 
                  log_params like '%5::newgroups%"bureaucrat"%') as "+بيروقراط",
                  (select count(*) from logging where log_user = user_id and log_type = "rights" and 
                  log_params like '%5::newgroups%"accountcreator"%') as "+منشئ حسابات",
                  (select count(*) from logging where log_user = user_id and log_type = "rights" and 
                  log_params like '%5::newgroups%"import"%') as "+مستورد",
                  (select count(*) from logging where log_user = user_id and log_type = "rights" and 
                  log_params like '%::oldgroups"%"import"5::newgroups%') as "-مستورد",
                  (select count(*) from logging where log_user = user_id and log_type = "rights" and 
                  log_params like '%::oldgroups"%"accountcreator"5::newgroups%') as "-منشئ حسابات",
                   (select count(*) from logging where log_user = user_id and log_type = "rights" and 
                  log_params like '%::oldgroups"%"bot"5::newgroups%') as "-بوت"
from user
inner join user_groups 
on ug_user = user_id
where ug_group = "bureaucrat";
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...