Number of votes on answers to older questions in past 30 days

0

Please login or register to vote for this query.

(click on this box to dismiss)

Magento

Q&A for users of the Magento e-Commerce platform

SELECT COUNT(*) 
FROM Votes
JOIN Posts as p1
ON Votes.PostId = p1.Id
Join Posts as p2
ON p1.ParentId = p2.Id
WHERE Votes.VoteTypeId IN (2,3) AND Votes.CreationDate >= DATEADD(DAY,-30,GETDATE()) AND p1.PostTypeId IN (2) AND p1.ParentId IS NOT NULL AND p2.PostTypeId IN (1) AND p2.CreationDate <= DATEADD(DAY, -120, GETDATE())

Enter Parameters

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