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

SQL

x
 
use zhwiki_p;
SET @VOTE_TIME = '20241001000000';
SET @PRIOR_90_VOTE_TIME =
        DATE_FORMAT(DATE_SUB(STR_TO_DATE(@VOTE_TIME, '%Y%m%d%H%i%s'), INTERVAL 90 DAY), '%Y%m%d%H%i%s');
SET @PRIOR_120_VOTE_TIME =
        DATE_FORMAT(DATE_SUB(STR_TO_DATE(@VOTE_TIME, '%Y%m%d%H%i%s'), INTERVAL 120 DAY), '%Y%m%d%H%i%s');
EXPLAIN
SELECT rev_id, rev_actor, rev_page, rev_timestamp
                      FROM revision_userindex
                      UNION
                      SELECT ar_id        AS rev_id,
                             ar_actor     AS rev_actor,
                             ar_page_id   AS rev_page,
                             ar_timestamp AS rev_timestamp
                      FROM archive_userindex;
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...