Count of questions with Rust tag over time

0

Please login or register to vote for this query.

(click on this box to dismiss)

The Workplace Meta

Q&A about the site for members of the workforce navigating the professional setting

DECLARE @firstdayofmonth varchar(8);
SELECT @firstdayofmonth =
  CONVERT(varchar(8), DATEADD(
    month,
    DATEDIFF(month, '20120101', CURRENT_TIMESTAMP), '20120101') , 112);
    



SELECT 
  DATEADD(MONTH, DATEDIFF(MONTH, 0, CreationDate), 0) AS [MONTH]
  , COUNT(DISTINCT Posts.Id) AS Count
FROM Posts
INNER JOIN PostTags ON PostTags.PostId = Posts.Id
INNER JOIN Tags ON PostTags.TagId = Tags.Id
WHERE Tags.TagName like '%rust%' AND PostTypeId = 1 AND CreationDate < @firstdayofmonth
GROUP BY DATEADD(MONTH, DATEDIFF(MONTH, 0, CreationDate), 0)
ORDER BY [MONTH] ASC

Enter Parameters

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