Q&A for professional and enthusiast programmers
select count(mainposts.id) from posts as mainposts where creationdate > '2022-01-01 00:00:00' and creationdate < '2023-01-01 00:00:00' and score > (select score from posts as parent where mainposts.parentid = parent.id)