select count(1) from posts p where posttypeid = 1 and p.c...

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(1) 
from posts p
where posttypeid = 1
and p.creationdate >= dateadd(month,datediff(month,0,getdate()) - 1,0)
and p.creationdate <= dateadd(day,-1,dateadd(month,datediff(month,-2,getdate()),0))

Enter Parameters

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