Q&A for professional and enthusiast programmers
select datefromparts(year(DeletionDate), month(DeletionDate), 1), count(datefromparts(year(DeletionDate), month(DeletionDate), 1)) from PostsWithDeleted where PostTypeId=2 and DeletionDate is not null group by datefromparts(year(DeletionDate), month(DeletionDate), 1) order by datefromparts(year(DeletionDate), month(DeletionDate), 1);