WITH answered_posts AS( SELECT a.AcceptedAnswerId, a.Crea...


Please login or register to vote for this query.

(click on this box to dismiss)

Academia Meta

Q&A about the site for academics and those enrolled in higher education

WITH answered_posts AS(
SELECT a.AcceptedAnswerId, a.CreationDate
FROM Posts a
GROUP BY a.AcceptedAnswerId, a.CreationDate),

questions AS(
SELECT q.Id, q.CreationDate
FROM Posts q
WHERE year(q.CreationDate) = '2017'
GROUP BY q.Id, q.CreationDate),

dates_joined AS(
SELECT a.CreationDate AS DateAnswered, q.CreationDate AS DatePosted
FROM questions q
INNER JOIN answered_posts a
ON a.AcceptedAnswerId = q.Id)

AVG(DATEDIFF(day, DateAnswered, DatePosted))/86400 AS DateDiff
FROM dates_joined q;

Enter Parameters

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