Q&A for designers and implementers of computer programming languages
DECLARE @UserId int = ##UserId## SELECT ROW_NUMBER() OVER(ORDER BY Reputation DESC) AS [#], Id AS [User Link], Reputation FROM Users WHERE Id = @UserId ORDER BY Reputation DESC;