Anonymous Feedback for a Specific Post

1

Please login or register to vote for this query.

(click on this box to dismiss)

History of Science and Math

Q&A for people interested in the history and origins of science and mathematics

Select top 100 postid as [Post Link], 
  SUM(CASE WHEN VoteTypeId = 2 THEN 1 ELSE 0 END) AS 'number of up votes',
  SUM(CASE WHEN VoteTypeId = 3 THEN 1 ELSE 0 END) AS 'number of down votes'
From PostFeedback
where exists(
    select id from posts 
    where posts.id=postfeedback.postid
)
group by postid
order by 'number of up votes' desc

Enter Parameters

Options:
Switch to meta site
loading Hold tight while we fetch your results