Questions that receive at least one answer on the same day they were asked


Please login or register to vote for this query.

(click on this box to dismiss)

Craft CMS Meta

Q&A about the site for administrators, end users, developers and designers for Craft CMS

SELECT datasource.SameDayAnswer, datasource.TotalQuestions, CAST(datasource.SameDayAnswer AS FLOAT) / CAST(datasource.TotalQuestions AS FLOAT) as Ratio FROM (SELECT COUNT(initialresponses.questionid) as SameDayAnswer, allquestions.totalcount as TotalQuestions FROM (SELECT allanswers.questionid AS questionid, MIN(allanswers.timediff) AS mintimediff FROM (select as questionid, cast(answer.creationdate - question.creationdate as float) as timediff from posts question join posts answer on answer.parentid = where question.posttypeid = '1') allanswers GROUP BY allanswers.questionid) initialresponses LEFT OUTER JOIN (SELECT COUNT(id) AS totalcount FROM posts WHERE posttypeid = '1') allquestions ON 1=1 WHERE initialresponses.mintimediff <= 1 GROUP BY allquestions.totalcount) datasource

Enter Parameters

Switch sites:
loading Hold tight while we fetch your results