My self answers


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

'site://a/' + CAST(a.Id AS NVARCHAR) + '/' + CAST(m.Id AS NVARCHAR) + '|' + q.Title AS atl,
q.tags AS qta,
COALESCE('site://users/' + CAST(a.OwnerUserId AS NVARCHAR) + '|' + u.DisplayName, a.OwnerDisplayName) AS uli,
a.CreationDate AS ada,
a.Id AS aid
FROM Posts AS a
JOIN Posts AS q ON a.ParentId = q.Id
LEFT JOIN users AS u ON u.Id = a.OwnerUserId
LEFT JOIN Users AS m ON m.AccountId = 1192385
WHERE 2 = a.PostTypeId AND 
(q.OwnerUserId = a.OwnerUserId OR q.OwnerDisplayName = a.OwnerDisplayName)
AND q.OwnerUserId = m.Id
ORDER BY q.Id, a.Id;

Enter Parameters

Switch to meta site
loading Hold tight while we fetch your results