select * from dbo.response_msg_log
where datepart(hh,ResponseTime) between 8 and 20
and convert(varchar(10),getdate(),120)=convert(varchar(10),ResponseTime,120)select * from dbo.response_msg_log
where datepart(hh,ResponseTime) between 8 and 20
and convert(varchar(10),getdate(),120)=convert(varchar(10),ResponseTime,120)