select p.id as [Post Link], count(*) from posts p inner j...

0

Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow

Q&A for professional and enthusiast programmers

select p.id as [Post Link], count(*)
from posts p
inner join posttags pt on pt.postid = p.id
left outer join posttags p2 on p2.postid = p.id and p2.tagid <> pt.tagid
inner join tags t on t.id = pt.tagid
where t.tagname = 'user'
and p2.postid is null
group by p.id
having count(*) = 1

Enter Parameters

Options:
Switch sites:
loading Hold tight while we fetch your results