工作中编写过的一条语句 select * from Bt_Holiday where to_char(Setting_DATE,'YYYY')=Substr('2015-03-00',1,4) AND to_char(Setting_DATE,'MM')=Substr('2015-03-00',6, (instr('2015-03-00','-',1,2))-(instr('2015-03-00','-',1)+1)) Substr('2015-03-00',6, (instr('2015-03
select )) h, )) m, )) s from gat_data_record gdr where gdr.enddt between to_date('2011-1-1','yyyy-mm-dd') and to_date('2014-2-1','yyyy-mm-dd') 1.获得时间差毫秒数: select ceil((To_date('2008-05-02 00:00:00' , 'yyyy-mm-dd hh24-mi-ss') - To_date('2008-04-30 23:
1.日期比较 --1.在确定时间之前: select * from up_date where update < to_date('2018-06-05 00:00:00','yyyy-mm-dd hh24:mi:ss') select * from up_date where update <= to_date('2018-06-05 00:00:00','yyyy-mm-dd hh24:mi:ss') --2.在确定时间之后: select * from up_date where upd