Oracle insert update 时间处理
                        
                            时间:2021-07-01 10:21:17
                            帮助过:5人阅读
							                        
                     
                    
                    
                    -06-30 23:
59:
59’,’yyyy
-mm
-dd hh24:mi:ss’)
12小时表示方法:to_date(’2004-06-30 23:
59:
59’,’yyyy
-mm
-dd hh:mi:ss’)
 
 
insert into settle_white 
values(
‘15‘,
‘S7551581‘,to_date(
‘2016-04-12 20:20:59‘,
‘yyyy-mm-dd hh24:mi:ss‘),
to_date(‘2016-04-12 20:20:59‘,
‘yyyy-mm-dd hh24:mi:ss‘),
‘0‘,
‘1‘,sysdate,sysdate,
‘aaa‘);
 
 
 
update settle_white t 
SET t.start_tm 
= to_date(
‘2016-04-12 20:50:59‘,
‘yyyy-mm-dd hh24:mi:ss‘),
t.end_tm = to_date(
‘2016-04-12 20:50:59‘,
‘yyyy-mm-dd hh24:mi:ss‘)  
where t.white_id 
= ‘FC7551581‘;
 
 
-- 查询当前时间
 select to_char(sysdate,
‘yyyy-MM-dd HH24:mi:ss‘) 
from dual;
 
Oracle insert update 时间处理
标签: