Users offering the most reputation through bounties

0

Please login or register to vote for this query.

(click on this box to dismiss)

Travel Answers

Q&A for road warriors and seasoned travelers

SELECT RANK() OVER (ORDER BY SUM(BountyAmount) DESC) AS 'Rank',
  UserId AS [User Link],
  COUNT(*) AS 'Number of bounties',
  SUM(BountyAmount) AS 'Reputation offered',
  IIF(Reputation = 1, NULL, ROUND(100.0 * SUM(BountyAmount) /
    (Reputation + SUM(BountyAmount)), 2)) AS 'Percentage'
  FROM Votes AS v
  INNER JOIN Users AS u ON v.UserId = u.Id
  WHERE VoteTypeId = 8 -- BountyStart
    AND UserId != -1 -- Exclude Community user
  GROUP BY UserId, Reputation
  ORDER BY SUM(BountyAmount) DESC

Enter Parameters

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