毫秒转换为日期
SELECT TO_CHAR(1406538765000 / (1000 * 60 * 60 * 24) + TO_DATE('1970-01-01 08:00:00', 'yyyy-MM-dd HH24:mi:ss'), 'yyyy-MM-dd HH24:mi:ss') AS CDATE FROM DUAL;

日期转换毫秒
SELECT TO_NUMBER(TO_DATE('2014-07-28 17:12:45', 'yyyy-MM-dd HH24:mi:ss') - TO_DATE('1970-01-01 08:00:00', 'yyyy-MM-dd HH24:mi:ss')) * 24 * 60 * 60 * 1000 FROM DUAL;

 


原文链接:https://blog.csdn.net/iteye_10264/article/details/82640226

 posted on 2021-05-21 09:05  xibuhaohao  阅读(430)  评论(0编辑  收藏  举报