Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ADD_MONTHS - How to get the exact date ?

847074Mar 24 2011 — edited Mar 24 2011
I am getting the below problem when using add_months function.

select ADD_MONTHS ('28-JAN-2011', 1) from dual;

The result of the above query is *'28-FEB-2011'.* This is fine.

select ADD_MONTHS ('28-FEB-2011', 1) from dual;

The result of the above query is *'31-MAR-2011'.*

But I need *'28-MAR-2011'* as result.

Is there anyway to get the exact date ?

Thanks!
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 21 2011
Added on Mar 24 2011
9 comments
313 views