Select data from the previous 3 months
You can use this methodology to determine the first day of 3 months ago, and the last day of the previous month:

select DATEADD(MONTH, DATEDIFF(MONTH, 0, GETDATE())-3, 0)   --First day of 3 months ago
select DATEADD(MONTH, DATEDIFF(MONTH, -1, GETDATE())-1, -1) --Last Day of previous month


Then, just use it on your where clause.

declare @start date = DATEADD(MONTH, DATEDIFF(MONTH, 0, GETDATE())-3, 0)
declare @end date = DATEADD(MONTH, DATEDIFF(MONTH, -1, GETDATE())-1, -1)

select *
from table
where dateField between @start and @end


If your dateField is datetime then you need to add the seconds, or just add a day and use a &lt; operand so you don't miss the last day

declare @start date = DATEADD(MONTH, DATEDIFF(MONTH, 0, GETDATE())-3, 0)
declare @end date = DATEADD(MONTH, DATEDIFF(MONTH, 0, GETDATE()), 0)        --First day of current month

select *
from table
where dateField &gt;=@start and dateField &lt; @end