Number of posts of a specific type per month (including deleted posts)

1

Please login or register to vote for this query.

(click on this box to dismiss)

Computational Science

Q&A for scientists using computers to solve scientific problems

SELECT eomonth(p.CreationDate) [month],
  COUNT(p.Id) AS [Count]
FROM PostsWithDeleted p
WHERE (p.CreationDate >= '##Date1?2021-01-01##') AND (p.CreationDate <= '##Date2?2023-01-01##')
  AND (p.PostTypeId IN (##types?1,2##))
---types=1: only questions
---types=2: only answers
---types=1,2: both questions and answers
GROUP BY eomonth(p.CreationDate)
ORDER BY eomonth(p.CreationDate)

Enter Parameters

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