Q&A for professional and enthusiast programmers
select p.id [Post Link], p.Score, count(stars.id) Star_count, p.answerCount, p.viewcount, p.title, p.body from votes myfavs INNER JOIN Posts P ON myfavs.PostId = P.Id INNER JOIN votes stars ON p.id = stars.PostId and stars.votetypeid = 5 where myfavs.votetypeid = 5 and myfavs.userid = ##UserId## group by p.id, p.Score, p.answerCount, p.viewcount, p.title, p.body