Q&A for professionals, academics, and students working within the systems development life cycle
-- How close are you to getting the Archaeologist badge?
-- "Edited 100 posts that were inactive for 6 months"
-- This is a rough estimate as the LastEditDate and LastActivityDate
-- changes as soon as you edit the post
DECLARE @UserId INT = ##UserId##;
SELECT TOP 10
FROM [PostHistory] [ph] (NOLOCK)
([ph].[PostHistoryTypeId] > 3 AND [ph].[PostHistoryTypeId] < 7) AND
[ph].[UserId] = @UserId
[ph].[PostId] DESC, [ph].[CreationDate] DESC