Most prolific users

0

Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow

Q&A for professional and enthusiast programmers

SELECT TOP 100
  OwnerUserId AS [User Link],
  SUM(CASE WHEN PostTypeId = 1 THEN 1 ELSE 0 END) AS QuestionCount,
  SUM(CASE WHEN PostTypeId = 2 THEN 1 ELSE 0 END) AS AnswerCount,
  SUM(CASE WHEN PostTypeId <= 2 THEN 1 ELSE 0 END) AS TotalCount
  
FROM Posts

GROUP BY OwnerUserId

ORDER BY QuestionCount DESC

Enter Parameters

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