Try using CAST instead like so:drop table #datediff
create table #DateDiff (
Verdate char(10) null
,secdate date null)
insert #DateDiff
values ('20140101', '20140201')
SELECT *
FROM #DateDiff
where datediff(DAY,cast(verdate as date), secdate) < 212Also notice that I created a table and some sample data to test with please do the same on future questions. Thanks