TIME STAMP SQL code example
Example 1: sql insert timestamp
INSERT INTO TABLE_NAME (TIMESTAMP_VALUE) VALUES (TO_TIMESTAMP('2014-07-02 06:14:00.742000000', 'YYYY-MM-DD HH24:MI:SS.FF'));
Example 2: sql server time stamp
SELECT SYSDATETIME()
,SYSDATETIMEOFFSET()
,SYSUTCDATETIME()
,CURRENT_TIMESTAMP
,GETDATE()
,GETUTCDATE();
Example 3: sql server time stamp
SELECT CONVERT (DATE, SYSDATETIME())
,CONVERT (DATE, SYSDATETIMEOFFSET())
,CONVERT (DATE, SYSUTCDATETIME())
,CONVERT (DATE, CURRENT_TIMESTAMP)
,CONVERT (DATE, GETDATE())
,CONVERT (DATE, GETUTCDATE());
Example 4: mysql timestamp format
INSERT INTO ... VALUES ('YYYY-MM-DD HH:MM:SS');