Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow

Q&A for professional and enthusiast programmers

select ROW_NUMBER() OVER (order by CloseVoteCount DESC), f.*, 'site://review/close/' + CAST(r.Id as nvarchar) from 
(select COUNT(*) as CloseVoteCount, PostId, PostId as [Post Link] 
from PendingFlags
where FlagTypeId=14 
group by PostId) f
inner join ReviewTasks r on r.ReviewTaskTypeId = 2 AND r.PostId = f.PostId
and f.CloseVoteCount = 4
where r.DeletionDate is NULL
order by CloseVoteCount DESC

Enter Parameters

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