SQL日期格式转换

时间:2021-06-30 13:46:00

CONVERT(nvarchar(20), [Date],101) as 'Date'    10/20/2016

CONVERT(nvarchar(20), [Date],102) as 'Date'    2016.10.20

CONVERT(nvarchar(20), [Date],103) as 'Date'    20/10/2016

CONVERT(nvarchar(20), [Date],104) as 'Date'    20.10.2016

CONVERT(nvarchar(20), [Date],105) as 'Date'    20-10-2016

CONVERT(nvarchar(20), [Date],106) as 'Date'    20 Oct 2016

CONVERT(nvarchar(20), [Date],107) as 'Date'    Oct 20, 2016

CONVERT(nvarchar(20), [Date],108) as 'Date'    13:31:54

CONVERT(nvarchar(20), [Date],109) as 'Date'    Oct 20 2016  1:31:54

CONVERT(nvarchar(20), [Date],110) as 'Date'    10-20-2016

CONVERT(nvarchar(20), [Date],111) as 'Date'     2016/10/20