DECLARE @StartDate datetime = '2016-07-01'; DECLARE @EndD...

0

Please login or register to vote for this query.

(click on this box to dismiss)

Open Source Meta

Q&A about the site for people organizing, marketing or licensing open source development projects

DECLARE @StartDate datetime = '2016-07-01';
DECLARE @EndDate datetime = '2021-07-01';

SELECT 
  dateadd(day, datediff(day, 0, creationdate), 0),
  count(*)
  FROM posts
  WHERE posttypeid = 1
    AND creationdate BETWEEN @StartDate AND @EndDate
  GROUP BY dateadd(day, datediff(day, 0, creationdate), 0)
  ORDER BY dateadd(day, datediff(day, 0, creationdate), 0)

Enter Parameters

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