WITH t1 AS ( SELECT u.Id AS user_id, COUNT(p.Id) AS numbe...

0

Please login or register to vote for this query.

(click on this box to dismiss)

History

Q&A for historians and history buffs

WITH t1 AS (
  SELECT u.Id AS user_id, COUNT(p.Id) AS number_of_posts_per_user
  FROM Users u
  LEFT JOIN Posts p
    ON u.Id = p.OwnerUserId
  GROUP BY u.Id
  )
SELECT 
  COUNT(t1.user_id)
FROM t1
WHERE t1.number_of_posts_per_user = 0;

Enter Parameters

Options:
Switch to meta site
loading Hold tight while we fetch your results