首页 > TAG信息列表 > DATENAME

sql语法

获取当月第一天 select CONVERT(nvarchar(50),DateAdd(dd,-datePart(day,GetDate())+1,GETDATE()),23) 2022-08-01 SELECT DATEADD(mm, DATEDIFF(mm,0,getdate()), 0) 2022-08-01 00:00:00.000 获取当月最后一天 select DATEADD(mm, DATEDIFF(m,0,getdate())+1, 0) 2022-09-