Bounty Amounts by quarter

0

Please login or register to vote for this query.

(click on this box to dismiss)

Language Learning

Q&A for students, teachers, polyglots, and anyone interested in the techniques of second-language acquisition

select DATEPART(year, CreationDate) as [Year]
     , DATEPART(q, CreationDate) as [Quarter]
     , sum(case when BountyAmount <= 100 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)

Enter Parameters

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