SELECT quest.CreationDate as [posted at], ans.CreationDat...

0

Please login or register to vote for this query.

(click on this box to dismiss)

Role-playing Games

Q&A for gamemasters and players of tabletop, paper-and-pencil role-playing games

SELECT
  quest.CreationDate as [posted at],
  ans.CreationDate as [answered at],
  DATEDIFF(SECOND, quest.CreationDate, ans.CreationDate) as [time to answer]
FROM Posts ans
  JOIN PostTypes pt ON pt.Id = ans.PostTypeId
  JOIN Posts quest ON quest.Id = ans.ParentId
WHERE ans.PostTypeId = 2 
  AND quest.CreationDate > '2018-01-01 00:00:00'

Enter Parameters

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