Questions that are closed as duplicates and nothing else

1

Please login or register to vote for this query.

(click on this box to dismiss)

Questions that are only closed as duplicates. No delete votes needed.

Physics

Q&A for active researchers, academics and students of physics

SELECT p.Score,
       p.Id                                                                AS [Post Link],
       COALESCE(p.AnswerCount, 0)                                          AS [Answer Count],
       CASE h.Comment
         WHEN '1' THEN 'duplicate'
       END                                                                 AS [Close Reason],
       CASE WHEN p.CommunityOwnedDate IS NOT NULL THEN 'Yes' ELSE NULL END AS Wiki,
       CASE WHEN h.UserId != -1                   THEN 'Yes' ELSE NULL END AS [Mod Closed],
       p.OwnerUserId                                                       AS [User Link]
FROM   Posts p
       INNER JOIN PostHistory h
         ON h.PostId = p.Id                   -- events pertaining to the question
            AND h.CreationDate = p.ClosedDate -- that occurred when it was closed
WHERE  p.PostTypeId = 1             -- questions
       AND p.ClosedDate IS NOT NULL -- that were closed
       AND h.PostHistoryTypeId = 10 -- and have a history entry for it
       AND h.Comment != 2           
       AND h.Comment != 3
       AND h.Comment != 4
       AND h.Comment != 7
ORDER  BY p.Score ASC

Enter Parameters

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