In my table
LoginDate
2013-08-29 13:55:48
The loginDate
column's datatype is nvarchar(150)
I want to convert the logindate
column into date time format using SQL command
Expected result.
LoginDate
29-08-2013 13:55:48
DECLARE @chr nvarchar(50) = (SELECT CONVERT(nvarchar(50), GETDATE(), 103))
SELECT @chr chars, CONVERT(date, @chr, 103) date_again