Most Upvoted Questions In A Tag

0

Please login or register to vote for this query.

(click on this box to dismiss)

The top 20 questions with the most down-votes (ignores up-votes)

Moderators

Q&A for community managers, administrators, and moderators

-- Most Upvoted Questions In A Tag

DECLARE @tagName nvarchar(max) = '##tag##'

SELECT TOP 200
  Posts.Id as [Post Link],
  Posts.Score,
  Posts.AnswerCount
FROM PostTags
  INNER JOIN Posts on PostTags.PostId = Posts.Id
  INNER JOIN Tags on PostTags.TagId = Tags.Id
WHERE Posts.PostTypeId = 1 AND Tags.TagName = @tagName
GROUP BY Posts.Id, Posts.Score, Posts.AnswerCount
ORDER BY Posts.Score DESC

Enter Parameters

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