Number of tag additions by per user

1

Please login or register to vote for this query.

(click on this box to dismiss)

Christianity

Q&A for committed Christians, experts in Christianity and those interested in learning more

with firstrev_cte AS
(
SELECT MIN(ph.Id) AS MinId, p.Id
FROM Posts p JOIN PostHistory ph ON ph.PostId=p.Id
WHERE ph.Text LIKE '%<##tagName##>%'
GROUP BY p.Id
)
, users_cte AS
(SELECT PostId AS pid, UserId AS uid, UserDisplayName AS udn
FROM PostHistory INNER JOIN firstrev_cte ON PostHistory.Id=MinId)

SELECT
  COUNT(pid), uid AS [User Link], udn
  FROM users_cte
GROUP BY uid, udn
ORDER BY COUNT(pid) DESC

Enter Parameters

Options:
Switch sites:
loading Hold tight while we fetch your results