Q&A for professional and enthusiast programmers
select top (##TopX?100##) row_number() over (order by DownVotes desc, UpVotes asc, DisplayName, Id) as Rank, Id as [User Link], DownVotes, UpVotes, LastAccessDate into #Downvoters from Users where Id <> -1 select * from #Downvoters order by Rank select Rank, DownVotes from #Downvoters order by Rank