I am trying to run the below query but i get the error
select * from table where Convert(VARCHAR,dbo.table.starttime,103) between starttime and endtime
where starttime and endtime are datetime variables
Till recently this worked but all of sudden i get the below error with the query
Msg 8114, Level 16, State 5,
Error converting data type nvarchar to datetime.
Thanks for the help