stackoverflow top 2018 tags

0

Please login or register to vote for this query.

(click on this box to dismiss)

Joomla

Q&A for Joomla! administrators, users, developers and designers

SELECT t.TagName, COUNT(DISTINCT OwnerUserId) AS cnt
FROM
PostTags AS pt
LEFT JOIN
(SELECT Id, OwnerUserId FROM Posts WHERE YEAR(CreationDate)=2018 AND Tags IS NOT NULL) AS p
ON pt.PostId=p.Id
LEFT JOIN 
Tags AS t ON pt.TagId=t.Id
WHERE pt.TagId IS NOT NULL AND p.Id IS NOT NULL 
GROUP BY t.TagName
ORDER BY cnt DESC

Enter Parameters

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