Convert NVARCHAR to DATETIME in SQL Server 2008 -
in table
logindate 2013-08-29 13:55:48
the logindate
column's datatype nvarchar(150)
i want convert logindate
column 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
Comments
Post a Comment