Percentage of unanswered question (zero answers) per month

0

Please login or register to vote for this query.

(click on this box to dismiss)

MathOverflow

Q&A for professional mathematicians

; with counts_cte AS (
SELECT
  eomonth(q.creationdate) AS CMonth,
  COUNT(q.Id) AS Qall,
  SUM(case when q.AnswerCount = 0 then 1 else 0 end) AS Qzero
FROM Posts q
  WHERE (q.PostTypeId=1)
GROUP BY eomonth(q.creationdate)
)

SELECT
  CMonth,
  ROUND((CAST(Qzero AS decimal))*100.0/(CAST(Qall AS decimal)),2) AS Percentage
FROM counts_cte
ORDER BY CMonth

Enter Parameters

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