oracle中日期函数

 select current_date,
       current_timestamp,
       dbtimezone,
       extract(year from sysdate),
       extract(month from sysdate),
       extract(day from sysdate),
       last_day(sysdate),
       months_between(to_date(200507,'yyyymm'),sysdate),
       add_months(to_date(200507,'yyyymm'),7),
       add_months(to_date(200501,'yyyymm'),-1)
  from dual;


2007-12-14 18:32:46 14-12月-07 06.32.46.243231 下午 +08:00 +08:00 2007 12 14 2007-12-31 18:32:46 -29.4442824074074 2006-2-1 2004-12-1

你可能感兴趣的:(oracle)