Answered question closed by himself

1

Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow на русском Meta

Вопросы и ответы о сайте для программистов

SELECT PostId, Id, Text
FROM PostHistory
WHERE Id IN (
  SELECT MAX(Id) AS CloseEventId
  FROM PostHistory
  WHERE
    PostHistoryTypeId = 10
    AND
    PostId IN (
      SELECT Id
      FROM Posts
      WHERE ClosedDate IS NOT NULL
    )
  GROUP BY PostId
)

Enter Parameters

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