Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-38516

TO_DATE: 'J' format element not supported and not listed as unsupported

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Critical
    • Resolution: Won't Fix
    • N/A
    • N/A
    • Server
    • None
    • Not for Release Notes

    Description

      In Oracle, TO_DATE allows 'J' (Julian day; the number of days since January 1, 4712 BC).
      In MariaDB it does not work, and it is not listed in the commit comment either as a supported or unsupported element. Maybe it results from BC not being supported, which the comment does say; in this case, it's just a documentation issue – I think all unsupported formats need to be explicitly listed, to avoid confusion.

      bb-12.3-MDEV-19683-to_date f45636ea81a5a02444833e993e47c262ed52f384

      MariaDB [test]> SELECT TO_DATE('1721426','J') AS x;
      ERROR 3047 (HY000): Invalid argument error: date format not recognized at J in function to_date.
      

      Oracle

      SELECT TO_DATE('1721426','J') AS x;
       
      X
      03-JAN-01
      

      Attachments

        Issue Links

          Activity

            People

              monty Michael Widenius
              elenst Elena Stepanova
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.