thanks to http://data.stackexchange.com/stackoverflow/s/1506/average-answer-score
Q&A about the site for enthusiasts and scholars of mythology and folklore
-- Min, max, and average of score to view count ratios per question over a given year -- thanks to http://data.stackexchange.com/stackoverflow/s/1506/average-answer-score SELECT MIN(cast(Score as decimal)/cast(viewcount as decimal)) AS "Minimum", MAX(cast(Score as decimal)/cast(viewcount as decimal)) AS "Maximum", (SUM(cast(Score as decimal)/cast(viewcount as decimal)) + 0.0) / Count(*) AS "Average" FROM posts WHERE creationdate >= cast(##year:int## as char) + '-01-01' and creationdate < cast((##year:int## + 1) as char) + '-01-01' and posttypeid = 1