Top Answerers for a Given Tag

0

Please login or register to vote for this query.

(click on this box to dismiss)

The Stats of a Tag only gives the Top-20 answerers. This query can list more of them and give other info as well.

Physical Fitness Meta

Q&A about the site for physical fitness professionals, athletes, trainers, and those providing health-related needs

-- Top Answerers for a Given Tag
-- The Stats of a Tag only gives the Top-20 answerers. This query can list more of them and give other info as well.
SELECT TOP 100
    Users.Id as [User Link],
    max(Age),
    max(Location),
    max(WebsiteUrl),
    Count(Posts.Id) as Answers,
    sum(Score) as Score,
    CAST(AVG(CAST(Score AS float)) as numeric(6,2)) as [Average Answer Score],
    COUNT(*) AS UpVotes 
FROM Posts    
    INNER JOIN Users ON Users.Id = OwnerUserId
    INNER JOIN PostTags ON PostTags.PostId = Posts.Id
    INNER JOIN Tags ON Tags.Id = PostTags.TagId
WHERE     
TagName = 'debugging'
GROUP BY 
    Users.Id, DisplayName
ORDER BY 
    Score DESC

Enter Parameters

Options:
Switch sites:
loading Hold tight while we fetch your results