Tags with a high proportion of zero-vote accepted answers

0

Please login or register to vote for this query.

(click on this box to dismiss)

Woodworking

Q&A for professional and amateur woodworkers

-- Tags with a high proportion of zero-vote accepted answers

SELECT
    (Questions / 1000) * 1000,
    MAX( AcceptedPercent ),
    COUNT(*),
    SUM( AcceptedPercent * Questions ),
    MIN( TagName )
    
FROM (
SELECT t.TagName
, COUNT(*) AS 'Questions'
, CAST( COUNT(a.id) AS FLOAT ) / COUNT(*) AS 'AcceptedPercent'
FROM Tags t
LEFT JOIN
     PostTags pt
ON   t.id = pt.TagId
LEFT OUTER JOIN
     Posts p
ON   pt.PostId = p.id
AND  p.AcceptedAnswerId != 0
LEFT JOIN
     Posts a
ON   a.Id = p.AcceptedAnswerId
AND a.Score = 0
GROUP BY t.TagName
HAVING COUNT(*) > 1000
) x
GROUP BY Questions / 1000
ORDER BY 2 DESC

Enter Parameters

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