Q&A about the site for members of the workforce navigating the professional setting
SELECT TOP 50 p.* ,p2.* /*p.Title, p.Id, p.Score, p.ViewCount, u.DisplayName */ FROM Posts p full outer JOIN Posts p2 ON p2.ParentId = p.Id /*JOIN Users u ON p.OwnerUserId = u.Id*/ /*WHERE p.PostTypeId = 1 and p2.PostTypeId = 2*/ /*JOIN Users u ON p.OwnerUserId = u.Id*/ /*JOIN SuggestedEdits s ON p.Id = s.PostId*/ /*JOIN Comments c ON c.PostId = p.Id*/ /*JOIN Posts p2 ON p2.ParentId = p.AcceptedAnswerId*/ /*WHERE p.PostTypeId = 1 AND p.Tags IS NOT NULL*/ /*WHERE p.PostTypeId = 1 and p2.PostTypeId = 2 and p.Tags IS NOT NULL*/ /*FROM Posts p JOIN Users u ON p.OwnerUserId = u.Id*/ /*JOIN SuggestedEdits s ON p.Id = s.PostId*/ /*JOIN Comments c ON c.PostId = p.Id*/ /*JOIN Posts p2 ON p2.ParentId = p.AcceptedAnswerId*/ /*WHERE p.PostTypeId = 1 AND p.Tags IS NOT NULL*/ /*WHERE p.Tags IS NOT NULL*/ /* union all 再试一下 SELECT TOP 10 * FROM Posts p JOIN Users u ON p.OwnerUserId = u.Id JOIN SuggestedEdits s ON p.Id = s.PostId*/ /*FULL OUTER JOIN Posts p2 ON p2.ParentId = p.AcceptedAnswerId*/ /*WHERE p.PostTypeId = 2 AND p.Tags IS NOT NULL*/ /* SELECT TOP 10 * FROM Posts*/