Count of questions by "newish" users

0

Please login or register to vote for this query.

(click on this box to dismiss)

MathOverflow

Q&A for professional mathematicians

SELECT
  eomonth(q.CreationDate),
  SUM(case when (DATEDIFF(day, u.CreationDate, q.CreationDate)<=##days?100##) then 1 else 0 end) AS [New Users],
  COUNT(q.Id) AS [All questions]
FROM Posts q INNER JOIN Users u ON q.OwnerUserId=u.Id
WHERE (q.PostTypeId=1) --only questions
GROUP BY eomonth(q.CreationDate)
ORDER BY eomonth(q.CreationDate)

Enter Parameters

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