For SQL Server, I will use the following. for example: from March 1 to June 31
select * from ( select *,DATEFROMPARTS(2011,MONTH(CreateDate),DAY(CreateDate)) as dt from tblAction ) as x where x.dt between DATEFROMPARTS(2011,3,1) and DATEFROMPARTS(2011,6,31)
See if that helps. :)
source share