Q&A about the site for people looking to bypass life's everyday problems with simple tricks
SELECT DATEPART(MONTH, Posts.CreationDate) as Month, COUNT(*) as PostCount, AVG(CAST(Posts.Score as FLOAT)) as AvgScore, SUM(Posts.ViewCount) as TotalViews FROM Posts LEFT JOIN PostTags ON Posts.Id = PostTags.PostId LEFT JOIN Tags ON PostTags.TagId = Tags.Id WHERE Tags.TagName IN ('seasonal', 'peak-season', 'off-season', 'holidays') AND Posts.PostTypeId = 1 GROUP BY DATEPART(MONTH, Posts.CreationDate) ORDER BY Month;