Q&A about the site for mechanics and DIY enthusiast owners of cars, trucks, and motorcycles
select DATEPART(year, CreationDate) as [Year] , DATEPART(q, CreationDate) as [Quarter] , sum(case when BountyAmount >0 then 1 else 0 end) as [100] , count(*) from Votes where BountyAmount is not null group by DATEPART(year, CreationDate) , DATEPART(q, CreationDate) order by DATEPART(year, CreationDate) , DATEPART(q, CreationDate)