Users with more than one Suffrage badge

0

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 userid as [User Link], [Suffrage]
from(select userid, [Suffrage] 
from (
    select id, userid, name from badges where tagbased = 0
  ) as data
  pivot 
  (count(data.id)
    for name in ([Suffrage]
    ) 
  ) pvt
  where [Suffrage] > 1
) main 
inner join users u on u.id = main.userid -- for reputation
order by displayname

Enter Parameters

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