I**A 发帖数: 2345 | 1 given a date, how to get the new date which is 2 days later..
for instance, now i have 30-Sep-2010, i want to get the date 2-Oct-2010
thanks a lot~ | f*******h 发帖数: 53 | 2 select to_date('30-Sep-2010','dd-MON-yyyy')+2 from dual | d**e 发帖数: 6098 | 3 直接 + 2
【在 I**A 的大作中提到】 : given a date, how to get the new date which is 2 days later.. : for instance, now i have 30-Sep-2010, i want to get the date 2-Oct-2010 : thanks a lot~
| l******e 发帖数: 12192 | 4 你咋还在找?不是已经工作了么
【在 I**A 的大作中提到】 : given a date, how to get the new date which is 2 days later.. : for instance, now i have 30-Sep-2010, i want to get the date 2-Oct-2010 : thanks a lot~
| I**A 发帖数: 2345 | 5 freshfish is right, directly +2 not work dih, need to_date
【在 d**e 的大作中提到】 : 直接 + 2
| d**e 发帖数: 6098 | 6 其实我说的就是在已经是date format下 + 2
'9/30/2010'或 '30-Sep-2010'这些只是varchar2之类的format
【在 I**A 的大作中提到】 : freshfish is right, directly +2 not work dih, need to_date
| h**********d 发帖数: 4313 | 7 Calendar cal = Calendar.getInstance();
cal.set(2010, 08, 30);
cal.add(Calendar.Day, 2); | I**A 发帖数: 2345 | 8 啊,I see。我就说嘛,只有我酱紫的生手才不知道.. :p
【在 d**e 的大作中提到】 : 其实我说的就是在已经是date format下 + 2 : '9/30/2010'或 '30-Sep-2010'这些只是varchar2之类的format
|
|