Manually protected questions

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 distinct PostId as [Post Link]
from PostHistory
where PostHistoryTypeId=19
and PostId not in 
 (select p.PostId 
  from PostHistory p
  join PostHistory up on up.PostId=p.PostId
  where p.PostHistoryTypeId=19
   and up.PostHistoryTypeId=20
  group by p.PostId
  having max(up.CreationDate) > max(p.CreationDate))
 
 and UserId <> -1

Enter Parameters

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