sql server only compare dates greater than or less than code example
Example: query less than datetime sql
select *
from dbo.March2010 A
where A.Date >= '2010-04-01'
select *
from dbo.March2010 A
where A.Date >= '2010-04-01'