Scrape SO

0

Please login or register to vote for this query.

(click on this box to dismiss)

Hinduism Meta

Q&A about the site for followers of the Hindu religion and those interested in learning more about Hinduism

SELECT
       pq.Id as id, 
       pq.Tags as tags, 
       pq.Title as title, 
       pq.Body as question,
       pa.Body as answers,
       pq.CreationDate as creation
     
FROM posts pq

LEFT JOIN (
  SELECT pa.ParentId, STRING_AGG(pa.Body, CHAR(10)) as body
  FROM posts pa
  WHERE ParentId IS NOT NULL
  GROUP BY pa.ParentId
) pa ON pa.ParentId = pq.id

WHERE pq.ParentId IS NULL AND Id > ##LOWER## AND Id < ##HIGHER##
ORDER BY Id

Enter Parameters

Options:
Switch to main site
loading Hold tight while we fetch your results