Q&A about the site for builders and users of networked sensors and control devices in the contexts of smart homes, industry automation, or environmental sensors
SELECT eomonth(q.CreationDate) AS [Month], COUNT(q.Id) AS [Total Count], SUM(Case When q.DeletionDate IS NULL Then 1 Else 0 End) AS [# Not Deleted] FROM PostsWithDeleted q WHERE (q.CreationDate >= '##Date1?2009-01-01##') AND (q.CreationDate <= '##Date2?2025-01-01##') AND (q.PostTypeId=##type?1##) ---PostTypeId=1 means only questions GROUP BY eomonth(q.CreationDate) ORDER BY eomonth(q.CreationDate)