List the top 200 bounty earners
Q&A for designers and users of artificial or invented languages, consciously developed instead of having developed naturally
-- Top 200 Bounty Earners -- List the top 200 bounty earners SELECT TOP 200 RANK() OVER (ORDER BY SUM(v.BountyAmount) DESC) AS [Rank], u.Id As [User Link], SUM(v.BountyAmount) as BountiesAmount, COUNT(v.BountyAmount) as BountiesCount FROM Users u INNER JOIN Posts p ON u.Id = p.OwnerUserId INNER JOIN Votes v ON p.Id = v.PostId WHERE v.VoteTypeId = 9 GROUP BY u.Id ORDER BY SUM(v.BountyAmount) DESC