Q&A about the site for people who build and repair bicycles, people who train cycling, or commute on bicycles
-- Query for retrieving IDs of questions with more than 5 answers and their average score SELECT p.Id AS QuestionId, AVG(a.Score) AS AverageScore FROM Posts p JOIN Posts a ON p.Id = a.ParentId WHERE p.PostTypeId = 1 AND p.AnswerCount > 5 AND a.PostTypeId = 2 GROUP BY p.Id;