第1个回答 2012-10-09
Oracle中Date类型是支持直接加减操作的,比如emp表:
select hiredate+30 “雇佣日期+30” from emp;
是可以的,默认加的是天数,应该可以满足楼主的需求
第2个回答 2012-10-09
使用函数 next_day(date, n)
如: select next_day(sysdate,1) from dual;
表示 当前日期往后推1天
第3个回答 2012-10-09
select to_date('20121220','yyyymmdd')+30 from dual;
第4个回答 2012-10-09
Select To_Date('2012-12-20','yyyy-mm-dd')+30 From Dual
第5个回答 2020-12-28
在sqlplus
设置当前会话的日期格式:
alter
session
set
nls_date_format
=
'yyyy
mm
dd
hh24:mi:ss';
也可以把它写入
./login.sql
中。