Posts by Aegon quoted with url.

0

Please login or register to vote for this query.

(click on this box to dismiss)

Science Fiction and Fantasy

Q&A for science fiction and fantasy enthusiasts

with PossibleQuotes as (
select
Q.Id,
substring(Q.Body, patindex('%scifi.stackexchange.com/a/%', Q.Body) + 26, 7) as Quote,
Q.OwnerUserId
from Posts Q
where 
--Q.OwnerUserId <> 54887
--and 
Q.Body like '%scifi.stackexchange.com/a/%'
)




select

P.Id as [Post Link],
Q.Id as [Post Link],
case when Q.OwnerUserId = 54887 then 'yes' else 'no' end as [SelfQuote?]

from Posts P

inner join PossibleQuotes Q
on Q.Quote like cast(P.Id as varchar) + '/%'

where P.OwnerUserId = 54887 and P.PostTypeId = 2

Enter Parameters

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