This query produces a list of your answers where the answer contains one or more "code " blocks.
Q&A for SharePoint enthusiasts
-- Answers by me that contain code. -- This query produces a list of your answers where the answer contains one or more "code " blocks. declare @UserId int = ##UserId## SELECT Id AS [Post Link], Score, Body FROM Posts WHERE OwnerUserID = @UserID AND Body LIKE '%<code>%' ORDER BY Score DESC