Duplicate hammers where the hammerer has a non-deleted answer


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 hc.UserId [User Link], p.id [Post Link], answers.score
from PostHistory hc
inner join posts p on hc.postid=p.id
inner join posts answers on answers.parentid=p.id and hc.userid=answers.owneruserid
inner join users u on hc.userid=u.id
where hc.PostHistoryTypeId=10
and hc.Comment like '101%'
and hc.Text like '%BindingReason":{"GoldTagBadge%'
and hc.CreationDate > getdate()-365
and DATEDIFF(day, p.CreationDate, hc.CreationDate) < 14
  SELECT * FROM PostHistory reopenHistory
  where reopenhistory.postid = p.id
  and posthistorytypeid = 11
  and reopenhistory.userid = hc.userid
  and Text like '%BindingReason":{"GoldTagBadge%'

order by score desc

Enter Parameters

Switch sites:
loading Hold tight while we fetch your results