Q&A for professional and enthusiast programmers
SELECT P.Id AS [Post Link], P.Body AS [Parent text], C.Text AS [Comment text], CASE WHEN P.PostTypeId = 1 THEN 'Question' WHEN P.PostTypeId = 2 THEN 'Answer' ELSE 'Unknown' END AS [Post Type], C.Score FROM Posts AS P JOIN Comments AS C ON P.Id = C.PostId WHERE C.Score >= 5 ORDER BY P.Id;