Top 100 users by hit rate (accepted answer percentage rate)

0

Please login or register to vote for this query.

(click on this box to dismiss)

100 users having the highest accepted answer percentage rate (among users with >100 answers)

Stack Overflow

Q&A for professional and enthusiast programmers

-- Top 100 users by hit rate (accepted answer percentage rate)
-- 100 users having the highest accepted answer percentage rate (among users with >100 answers)

SELECT TOP 1000
    u.Id AS [User Link],
    (CAST(SUM(CASE WHEN a.Id=q.AcceptedAnswerId THEN 1 ELSE 0 END) AS float) / COUNT(a.Id)) * 100 AS HitRate 
FROM Users u
    JOIN Posts a ON a.OwnerUserId = u.Id and a.PostTypeId = 2
    JOIN Posts q ON a.ParentId = q.Id
GROUP BY u.Id
HAVING COUNT(a.Id) > 100
ORDER BY HitRate DESC

Enter Parameters

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