Fork of Revocation of NPP rights by Winged Blades of Godric
This query is marked as a draft This query has been published by Cabayi.

SQL

AخA
 
SELECT u.user_name, ufg.ufg_user, ufg.ufg_group
 FROM  user_former_groups ufg,
       user u
 WHERE ufg.ufg_group = 'patroller'
 AND   u.user_id = ufg.ufg_user
 AND   NOT EXISTS (SELECT 'x'
                  FROM   user_groups ug
                  WHERE  ug.ug_user = u.user_id
                  AND    ( ug.ug_group = 'sysop'
                          OR ug.ug_group = 'patroller' ))
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...