select top 30 p.owneruserid as [User Link] , count(distin...

0

Please login or register to vote for this query.

(click on this box to dismiss)

Role-playing Games

Q&A for gamemasters and players of tabletop, paper-and-pencil role-playing games

select top 30
       p.owneruserid as [User Link]
       , count(distinct p.id) [# Answers]
       , sum(case votetypeid 
             when 2 then 1 
             when 3 then -1
             end) [score]
       , sum(case votetypeid 
             when 2 then 10 
             when 3 then -2
             end) [ reputation]
from posts p
inner join posttags pt on pt.postid = p.parentid
inner join tags t on t.id = pt.tagid
inner join votes v on v.postid = p.id
where t.tagname = ##tagname:string?angular##
and v.votetypeid in (2,3)
and p.creationdate between ##start:string?2019-09-15## and ##end:string?2019-10-15##
and v.creationdate <= ##end:string?2019-10-15##
group by p.owneruserid
order by sum(case votetypeid 
             when 2 then 10 
             when 3 then -2
             end) desc

Enter Parameters

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