Q&A for science fiction and fantasy enthusiasts
select top 20 pt.name, posts.id, ct.score from posts inner join posttypes pt on posts.posttypeid = pt.id inner join comments ct on posts.id = ct.postid order by ct.score desc