Distribution of scores on answers

0

Please login or register to vote for this query.

(click on this box to dismiss)

Number of answers with each score, for all scores that have at least one answer

Stack Overflow

Q&A for programmers

-- Question Vote Distribution
-- Number of posts with each score

SELECT Score, COUNT(*) AS Count
FROM Posts
WHERE PostTypeId = 1
Group By Score
ORDER BY Score ASC

--DECLARE @counter int
----SET @counter = -100
----WHILE @counter < 1000
--SET @counter = 1
--WHILE @counter < 31
--BEGIN
--
----DECLARE theSelect CURSOR FOR
--  SELECT
--    COUNT(*)
--  FROM
--    Posts
--  WHERE
--    PostTypeId = 1
--  AND
--    Score = @counter
----OPEN theSelect
--
--SET @counter = @counter + 1
--
--END

Enter Parameters

Options:
Switch sites:
loading Hold tight while we fetch your results