Number of users who were last seen in a given month (only users with 10 or more posts)

0

Please login or register to vote for this query.

(click on this box to dismiss)

Mathematics

Q&A for people studying math at any level and professionals in related fields

;  with counts_cte as
(
SELECT
  OwnerUserId AS uid,
  Count(Id) AS num
FROM Posts
GROUP BY OwnerUserId
)

SELECT
  eomonth(LastAccessDate), COUNT(u.Id)
FROM Users u JOIN counts_cte c ON u.Id=c.uid
WHERE c.num>=##min?10##
GROUP BY eomonth(LastAccessDate)
ORDER BY eomonth(LastAccessDate)

Enter Parameters

Options:
Switch sites:
loading Hold tight while we fetch your results