Average question score/views by hour

0

Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow

Q&A for professional and enthusiast programmers

-- Average answer score/views by hour

SELECT
DatePart(hh,CreationDate) Hour,
Round(Avg(Cast(Score as float)),2) AvgScore,
Avg(ViewCount) AvgViews
FROM Posts
WHERE PostTypeId = 1
GROUP BY DatePart(hh,CreationDate)

Enter Parameters

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