Q&A for professional and enthusiast programmers
SELECT datepart(year,p.CreationDate) + (datepart(month,p.CreationDate)-1)/12.0 as [date], Name, count(*) N FROM Posts p join PostTypes pt on p.PostTypeId = pt.Id join Posts q on isnull(p.ParentId, p.Id) = q.Id WHERE p.PostTypeId in (1,2) AND datepart(year, p.CreationDate) >= ##startYear?2010## AND datepart(year, p.CreationDate) <= ##endYear?2015## and q.ClosedDate is null and p.Score >= 0 and q.Score >= ##score?0## GROUP BY datepart(year,p.CreationDate) + (datepart(month,p.CreationDate)-1)/12.0, Name ORDER BY datepart(year,p.CreationDate) + (datepart(month,p.CreationDate)-1)/12.0, Name