Bounties created and awarded by month

1

Please login or register to vote for this query.

(click on this box to dismiss)

Science Fiction and Fantasy

Q&A for science fiction and fantasy enthusiasts

WITH Raw AS (
  SELECT
    DATEFROMPARTS(
      YEAR(Votes.CreationDate),
      MONTH(Votes.CreationDate),
      1) AS Month,
    VoteTypeId,
    SUM(BountyAmount) AS Rep
  FROM Votes
  WHERE VoteTypeId BETWEEN 8 AND 9
  GROUP BY
    VoteTypeId,
    DATEFROMPARTS(
      YEAR(Votes.CreationDate),
      MONTH(Votes.CreationDate),
      1)
)
SELECT Raw.Month, VoteTypes.Name, Raw.Rep
FROM Raw, VoteTypes
WHERE Raw.VoteTypeId = VoteTypes.Id
ORDER BY Raw.Month DESC, Raw.VoteTypeId

Enter Parameters

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