Q&A for Drupal developers and administrators
SELECT PostTypeId, COUNT(*) as NrOfPosts FROM posts WHERE YEAR(CreationDate) = '2019' GROUP BY PostTypeId;