Reputation vs New Reputation Only for Last Month

0

Please login or register to vote for this query.

(click on this box to dismiss)

Software Engineering

Q&A for professionals, academics, and students working within the systems development life cycle

SELECT top 100
    OwnerUserId,  
    SUM(Case WHEN v.VoteTypeID = 1 THEN 15
             WHEN v.VoteTypeID = 1 AND p.PostTypeID = 1 THEN  5
             WHEN v.VoteTypeID = 2 AND p.PostTypeID = 2 THEN  10
             WHEN v.VoteTypeID = 3 THEN  -2 END)  as RepEarned
FROM 
posts p
INNER JOIN Votes v
ON v.PostId = p.Id
GROUP BY 
  OwnerUserId
ORDER BY 
   RepEarned DESC

Enter Parameters

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