Users with the best Up/Down Vote ratio

1

Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow

Q&A for professional and enthusiast programmers

DECLARE @MinRep int = ##MinRep##
DECLARE @MinDownVotes int = ##MinDownVotes##
DECLARE @UserId int = ##UserId##

SELECT
    Id as [User Link],
    UpVotes,
    DownVotes,
    Reputation,
    ROUND(1000*CAST(DownVotes AS float) / CAST(Reputation AS float), 3) AS DownToRepPermil,
    ROUND(100*CAST(DownVotes AS float) / CAST(UpVotes+DownVotes AS float), 3) AS DownVotesPercent
FROM Users
WHERE Id=@UserId
OR (Reputation >= @MinRep
AND DownVotes >= @MinDownVotes)
ORDER BY DownToRepPermil ASC

Enter Parameters

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