Users with the most Tag Wiki Edits

0

Please login or register to vote for this query.

(click on this box to dismiss)

Craft CMS Meta

Q&A about the site for administrators, end users, developers and designers for Craft CMS

SELECT U.Id as [User Link], (SELECT Count(Pt.Id) FROM PostTypes Pt, PostHistoryTypes Pht, PostHistory Ph, Tags T WHERE Pt.Id = Ph.PostHistoryTypeId AND U.Id = Ph.UserId AND Pht.Id = 24 AND Pt.Id in (4,5) AND (Ph.PostId = T.ExcerptPostId OR Ph.PostId = T.WikiPostId) ) AS [EDITS] 
FROM Users U
WHERE
(SELECT Count(Pt.Id) FROM PostTypes Pt, PostHistoryTypes Pht, PostHistory Ph, Tags T WHERE Pt.Id = Ph.PostHistoryTypeId AND U.Id = Ph.UserId AND Pht.Id = 24 AND Pt.Id in (4,5) AND (Ph.PostId = T.ExcerptPostId OR Ph.PostId = T.WikiPostId) ) > 20
ORDER BY EDITS DESC

Enter Parameters

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