Users by approximate meta reputation

3

Please login or register to vote for this query.

(click on this box to dismiss)

Ask Ubuntu

Q&A for Ubuntu users and developers

-- Reconstructs (invisible) meta-reputation from votes
-- Not accounting for vote cap or community wikis
-- Based on http://data.stackexchange.com/{site}/query/215919/ by Cupcake

SELECT top ##number:int?100##
  u.Id as [User Link],
  SUM(CASE
    WHEN v.VoteTypeId = 1 THEN 15
    WHEN v.VoteTypeId = 2 AND p.PostTypeId = 1 THEN 5
    WHEN v.VoteTypeId = 2 AND p.PostTypeId = 2 THEN 10
    WHEN v.VoteTypeId = 3 THEN -2
  END) AS Reputation
FROM Posts p
  INNER JOIN Votes v ON p.Id = v.PostId
  INNER JOIN Users u ON p.OwnerUserId = u.Id
WHERE v.VoteTypeId IN (1,2,3) -- accepts,ups,downs
GROUP BY u.Id
ORDER BY REPUTATION DESC

Enter Parameters

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