current_tag_data

0

Please login or register to vote for this query.

(click on this box to dismiss)

Computer Science Educators

Q&A for those involved in the field of teaching Computer Science

SELECT 
  YEAR(p.CreationDate) AS year,
  t.TagName AS tag,
  COUNT(*) AS number,
  (SELECT COUNT(*) 
   FROM Posts 
   WHERE PostTypeId = 1 AND YEAR(CreationDate) = YEAR(p.CreationDate)) AS year_total
FROM 
  Posts p
  JOIN PostTags pt ON p.Id = pt.PostId
  JOIN Tags t ON pt.TagId = t.Id
WHERE 
  p.PostTypeId = 1  -- Only include questions
GROUP BY 
  YEAR(p.CreationDate), 
  t.TagName
ORDER BY 
  year, 
  number DESC;

Enter Parameters

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