Fork of Blocked UPEs on enwiki by Novem Linguae
This query is marked as a draft This query has been published by Novem Linguae.

SQL

AخA
 
SELECT actor_name AS blocking_admin,
    log_title AS blocked_user,
    comment_text AS block_reason,
    log_timestamp
FROM logging
JOIN comment_logging ON log_comment_id = comment_id
JOIN actor ON log_actor = actor_id
WHERE log_action = 'block'
AND (
    comment_text LIKE '%undisclosed paid%'
    OR comment_text LIKE '%upe%'   # LIKE isn't case sensitive. careful of false positives such as "super"
)
AND log_actor != 198977042   # proxy blocking bot
AND log_id > (
    SELECT log_id
    FROM logging
    WHERE log_timestamp > DATE_FORMAT(DATE_ADD(NOW(), INTERVAL -1 YEAR), "%Y%m%d%H%i%s")
    ORDER BY log_id
    ASC
    LIMIT 1 
)
ORDER BY log_id ASC
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...