Forum Stats

  • 3,853,235 Users
  • 2,264,195 Discussions
  • 7,905,291 Comments

Discussions

BC leap dates yyyy-02-29

User_3ABCE
User_3ABCE Member Posts: 104 Bronze Badge

The Oracle database considers leap date -0004-02-29 valid. SQL Plus shows such dates, but SQL Developer and SQLcl show the next day -0004-03-01 instead.

SQL*Plus> select date '-4-2-29', date'-4-3-1'-1 from dual;

DATE'-4-2-2 DATE'-4-3-1
----------- -----------
-0004-02-29 -0004-02-29

==========================================================

SQLcl> select date '-4-2-29', date'-4-3-1'-1 from dual;

DATE'-4-2-29'    DATE'-4-3-1'-1
________________ _________________
-0004-03-01      -0004-03-01