0

I have Unix Time column to convert to MSSQL time only. Any help is appreciated.

SELECT CONVERT(TIME, SWITCHOFFSET(DATEADD(SECOND, CAST('755' AS BIGINT), '19700101') ,  DATEPART(TZOFFSET,DATEADD(SECOND, CAST('755' AS INT), '19700101') AT TIME ZONE 'E. Australia Standard Time')))  AS [start_time] 

this gives me below answer but it is not correct. Any way to create the ms SQL time from unit time? enter image description here

SOUser
  • 31
  • 3
  • see [this](https://stackoverflow.com/questions/1177136/sql-server-function-to-convert-unix-time-to-local-datetime) and [this](https://stackoverflow.com/questions/40027625/how-to-convert-unix-time-in-microseconds-with-sql-server) – Squirrel May 09 '23 at 07:14
  • what does unix time column value contain for values? and what do you mean with "not correct"? please post original, expected, actual values together with an explanation – siggemannen May 09 '23 at 07:39

0 Answers0