SELECT COUNT_BIG(*), SUM(Q.ViewCount) FROM dbo.Posts AS A...

0

Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow

Q&A for professional and enthusiast programmers

SELECT
  COUNT_BIG(*), SUM(Q.ViewCount)
FROM dbo.Posts AS A
JOIN dbo.Posts AS Q
  ON Q.Id = A.ParentId
  AND Q.PostTypeId = 1
WHERE
  A.OwnerUserId = 1192
  AND A.PostTypeId = 2
  AND A.CreationDate >= '1 April 2019'
  AND A.DeletionDate IS NULL;

Enter Parameters

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