Most bookmarked (favorited) questions in the given tag


Please login or register to vote for this query.

(click on this box to dismiss)

Drupal Answers

Q&A for Drupal developers and administrators

SELECT TOP ##num?500##
       rank() over(order by count(*) desc) AS Rank, as [Post Link],
       count(*) [# bookmarks],
       p.OwnerUserId AS [User Link],
       p.Score, p.ViewCount, p.Tags
FROM Posts p INNER JOIN Votes v ON v.PostId=p.Id
  INNER JOIN PostTags pt ON p.Id = pt.PostId
  INNER JOIN Tags t ON pt.TagId = t.Id
WHERE (t.TagName=##tagname:string?diophantine-equations##)  
  AND (v.VoteTypeId = 5) -- favorite
group by, p.OwnerUserId, p.OwnerDisplayName, p.Score, p.ViewCount, p.Tags
order by count(*) desc

Enter Parameters

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