How to convert time and date stored in nDateTime of the TB_EVENT_LOG table to a normal format


nDateTimeĀ 

The number of seconds that have elapsed since January 1, 1970, 00:00:00. (Unix Time)

* What is Unix Time? : https://en.wikipedia.org/wiki/Unix_time


MSSQL

select dateadd(s,ndatetime, '1970-01-01 00:00:00') from TB_EVENT_LOG



Oracle

SELECT TO_CHAR(TO_DATE('19700101000000', 'yyyymmddhh24miss') + 1/(24*60*60) * nDateTime,'yyyy-mm-dd hh24:mi:ss') "sLogTime" FROM TB_EVENT_LOG;



MySQL

SELECT ADDDATE('1970-01-01', INTERVAL nDateTime SECOND) FROM TB_EVENT_LOG;