Count questions with specific text

0

Please login or register to vote for this query.

(click on this box to dismiss)

The Workplace Meta

Q&A about the site for members of the workforce navigating the professional setting

SELECT 
  DATEPART(year, p.CreationDate) AS "year",
  COUNT(*) AS "# questions"
FROM Posts p
  JOIN Users u ON u.Id = p.OwnerUserId
WHERE p.Body LIKE '%##SpecifiedText##%'
  AND p.PostTypeId = 1 -- Questions
GROUP BY DATEPART(year, p.CreationDate)
ORDER BY year DESC

Enter Parameters

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