Former sql to get the current time of day, without minutes and seconds

select convert(datetime,convert(char(20),dateadd(day,-1,getdate()),102))

-1 minus the number of days

getdate to get the current time

Guess you like

Origin www.cnblogs.com/superduan/p/11672318.html