Q&A about the site for expert genealogists and people interested in genealogy or family history
select *, count(*) from ( select CAST( cast(DATEPART(YYYY, CreationDate) as varchar) + '-' + cast(DATEPART(MM, CreationDate) as varchar) + '-01' as datetime) [Month], t.TagName from PostsWithDeleted p join PostTags pt on pt.PostId = p.Id join Tags t on t.Id = pt.TagId where TagName in ( SELECT TOP 10 TagName FROM Tags ORDER BY Tags.[Count] DESC ) ) as X group by TagName, [Month] order by [Month] asc, TagName asc