Q&A about the site for linguists, teachers and students of the Korean language
select Id, up_count, -down_count,Title from (select PostId, count(id) as up_count from votes where votetypeid = 2 group by PostId) as u INNER JOIN (select PostId, count(id) as down_count from votes where votetypeid = 3 group by PostId) as d on u.PostId=d.PostId Left JOIN Posts on u.PostId=Posts.Id