Must be modified getdate () format, between the two dates is determined whether

 

SELECT  *  from ZZ order table WHERE  the CONVERT ( VARCHAR ( 100 ), GETDATE (), 23 is ) > = Week start date and  the CONVERT ( VARCHAR ( 100 ), GETDATE (), 23 is ) <= Weeks End Date

 

CONVERT ( VARCHAR ( 100 ), GETDATE (), 23 ) 

- This format results: 2019-09-01 


- if you do not convert, check out contains the date and time, or two boundaries can not check out

 

Guess you like

Origin www.cnblogs.com/qqhfeng/p/11441822.html