Select posts without specific tag list


Please login or register to vote for this query.

(click on this box to dismiss)

Audio-Video Production Meta

Q&A about the site for engineers, producers, editors, and enthusiasts spanning the fields of video, and media creation

DECLARE @NumPosts INT = ##NumPosts?100##

CREATE TABLE #LanguageTags (
    TagName NVARCHAR(256) COLLATE SQL_Latin1_General_CP1_CS_AS

INSERT INTO #LanguageTags (TagName)

SELECT DISTINCT TOP (@NumPosts) p.Id AS [Post Link]
    , p.Tags
    , p.CreationDate AS [Created]
FROM Posts AS p
LEFT JOIN #LanguageTags AS lt
ON p.Tags LIKE '%' + lt.TagName + '%'
WHERE p.ClosedDate IS NULL
    AND lt.TagName IS NULL
    AND p.PostTypeId = 1

Enter Parameters

Switch sites:
loading Hold tight while we fetch your results