In MySQL, from_unixtime(lonvalue) returns the date format in
'YYYY-MM-DD HH:MM:SS'. Is there any equivalent available in SQL Server, to view the date in man readable format, when the input is an long value in milliseconds.
Eg :
SELECT FROM_UNIXTIME(875996580);
Thanks,
Smitha

MySQL function equivalent
Erland Sommarskog
select CONVERT(varchar, CURRENT_TIMESTAMP, 121) -- odbc canonical format
Daljinder
Output : 875996580
As I had said earlier, the input is a long value (in milliseconds)
HaLaBi
Roberto Kramer
isnt 'from_unixtime(longvalue)' return a date that is longvalue seconds from 1/1/1970 not milleseconds
select dateadd(s, 875996580, '1/1/1970')
yields:
1997-10-04 20:23:00.000