Users with low accept rates

0

Please login or register to vote for this query.

(click on this box to dismiss)

Shows users with accept rates below a certain threshold

Skeptics

Q&A for scientific skepticism

-- Users with low accept rates
-- Shows users with accept rates below a certain threshold
WITH QuestionCounts AS
(
  SELECT OwnerUserId AS UserId, COUNT(*) AS QuestionCount
  FROM Posts
  WHERE PostTypeId = 1
  GROUP BY OwnerUserId
),
AcceptedAnswerCounts AS
(
  SELECT q.OwnerUserId AS UserId, COUNT(*) AS AcceptedAnswerCount
  FROM Votes v
  INNER JOIN Posts p
    ON p.Id = v.PostId
  INNER JOIN Posts q
    ON q.Id = p.ParentId
  GROUP BY q.OwnerUserId
),
AcceptRates AS
(
  SELECT
    q.UserId,
    CAST(a.AcceptedAnswerCount AS float) / q.QuestionCount AS AcceptRate
  FROM QuestionCounts q
  INNER JOIN AcceptedAnswerCounts a
    ON a.UserId = q.UserId
  WHERE q.QuestionCount > ##MinQuestionCount##
)
SELECT TOP ##MaxResults## UserId AS [User Link], AcceptRate * 100
FROM AcceptRates
WHERE AcceptRate <= (##MaxAcceptRatePercent## / 100.0)
ORDER BY AcceptRate

Enter Parameters

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