Percentage of closed question per tag


Please login or register to vote for this query.

(click on this box to dismiss)

Computational Science

Q&A for scientists using computers to solve scientific problems

;  with closed_cte as 
(SELECT t.TagName AS tag, COUNT(q.Id) AS totalcount, COUNT(q.ClosedDate) AS closedcount,
  ROUND(COUNT(q.ClosedDate)*100.0/COUNT(q.Id),2) AS percentage
FROM PostsWithDeleted q
  INNER JOIN PostTags pt ON q.Id = pt.PostId
  INNER JOIN Tags t ON pt.TagId = t.Id
WHERE q.PostTypeId=1
GROUP BY t.TagName

SELECT tag, totalcount, closedcount, percentage
FROM closed_cte
WHERE totalcount>=##num?5000##
ORDER BY percentage DESC

Enter Parameters

Switch sites:
loading Hold tight while we fetch your results