Top Question Askwers

0

Please login or register to vote for this query.

(click on this box to dismiss)

SharePoint

Q&A for SharePoint enthusiasts

SELECT TOP 50 
  Users.DisplayName, 
  SUM(Posts.Score) AS TotalVotes,
  COUNT(Posts.Id) AS QuestionCount
FROM 
  Posts
JOIN 
  Users ON Posts.OwnerUserId = Users.Id
WHERE 
  Posts.PostTypeId = 1 -- PostTypeId = 1 refers to Questions
GROUP BY 
  Users.DisplayName
ORDER BY 
  TotalVotes DESC

Enter Parameters

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