--- 10位
select to_timestamp(1614826440) AT TIME ZONE 'PRC';
--- 13位
select to_timestamp(1614826440000 / 1000) AT TIME ZONE 'PRC';
–日期转时间戳
SELECT EXTRACT(epoch FROM NOW());
SELECT EXTRACT(epoch FROM CAST('2017-12-06 00:17:10' AS TIMESTAMP));