Question 5

0

Please login or register to vote for this query.

(click on this box to dismiss)

Amateur Radio

Q&A for amateur radio enthusiasts

SELECT TOP 10 
    STRING_AGG(Tags.TagName, ', ') AS Tags,
    Posts.Id AS PostId,
    Posts.OwnerUserId AS UserId,
    Posts.Body AS PostBody,
    COUNT(PostTags.TagId) AS NumberOfTags
FROM 
    Posts
JOIN PostTags ON Posts.Id = PostTags.PostId
JOIN Tags ON PostTags.TagId = Tags.Id
GROUP BY 
    Posts.Id, Posts.OwnerUserId, Posts.Body
HAVING 
    COUNT(PostTags.TagId) >= 5
ORDER BY 
    NumberOfTags DESC;

Enter Parameters

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