Q&A about the site for people who build and repair bicycles, people who train cycling, or commute on bicycles
SELECT 'site://q/' + CAST(Votes.PostId AS VARCHAR(MAX)) + '|' + CAST(Votes.PostId AS VARCHAR(MAX)) AS PostId, MIN(PostsWithDeleted.Score) AS Score, COUNT(*) AS Count, MIN(PostsWithDeleted.Tags) AS Tags FROM PostsWithDeleted, Votes WHERE Votes.PostId = PostsWithDeleted.Id AND Votes.VoteTypeId = 11 AND PostsWithDeleted.DeletionDate IS NOT NULL AND PostsWithDeleted.PostTypeId = 1 GROUP BY Votes.PostId ORDER BY Count DESC, Votes.PostId DESC