Q&A about the site for students, teachers, and linguists wanting to discuss the finer points of the Japanese language
-- Replace 'your_user_id' with your actual Stack Overflow user ID DECLARE @UserId INT = 9549068; SELECT p.Id AS [Post Link], p.Title, p.Score, v.VoteTypeId, CASE v.VoteTypeId WHEN 1 THEN 'AcceptedByOriginator' WHEN 2 THEN 'UpMod' WHEN 3 THEN 'DownMod' WHEN 4 THEN 'Offensive' WHEN 5 THEN 'Favorite' WHEN 6 THEN 'Close' WHEN 7 THEN 'Reopen' WHEN 8 THEN 'BountyStart' WHEN 9 THEN 'BountyClose' WHEN 10 THEN 'Deletion' WHEN 11 THEN 'Undeletion' WHEN 12 THEN 'Spam' WHEN 15 THEN 'ModeratorReview' END AS VoteType FROM Votes v JOIN Posts p ON p.Id = v.PostId JOIN PostTags pt ON pt.PostId = p.Id JOIN Tags t ON t.Id = pt.TagId WHERE v.UserId = @UserId AND t.TagName = 'powershell' ORDER BY v.CreationDate DESC;