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

SQL

x
 
WITH newusers(nu_name) AS
(
  SELECT user_name
  FROM user
  WHERE user_registration LIKE '2023%'
    AND user_editcount >= 1
)
SELECT COUNT(DISTINCT nu_name) AS 'accounts created in 2023'
FROM newusers;
WITH newusers(nu_name) AS
(
  SELECT REPLACE(user_name, ' ', '_')
  FROM user
  WHERE user_registration LIKE '2023%'
    AND user_editcount >= 1
)
SELECT COUNT(DISTINCT nu_name) AS 'accounts created in 2023, ever blocked'
FROM newusers
JOIN logging_logindex ON log_namespace = 2 AND log_title = nu_name
WHERE log_type = 'block'
  AND log_action IN ('block', 'reblock')
  AND log_params LIKE '%"sitewide";b:1%';
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...