Oracle数据库中 to_date()函数的用法
--日期到字符串
select to_char(sysdate,'yyyy-mm-dd hh24:mi:ss') as uptime from dual
--字符到日期
select to_date('2018-08-28 08:08:08', 'yyyy-mm-dd hh24:mi:ss') as uptime from dual
--当前时间毫秒
select ((sysdate - to_date('1970-01-01 08:00:00', 'yyyy-mm-dd hh24:mi:ss')) *1000 * 60 * 60 * 24) as uptime from dual
浙公网安备 33010602011771号