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

LP:1034131 - select unix_timestamp('0000-00-00') returns NULL instead of 0

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Resolution: Not a Bug
    • None
    • None
    • None

    Description

      MariaDB 5.3.7 returns NULL instead of expected 0 for the the following query:

      MariaDB [(none)]> select unix_timestamp('0000-00-00');
      ------------------------------

      unix_timestamp('0000-00-00')

      ------------------------------

      NULL

      ------------------------------
      1 row in set (0.00 sec)

      Replacing MariaDB with MySQL 5.1 (Percona SQL server) returns expected 0 as in MySQL 5.0

      mysql> select unix_timestamp('0000-00-00');
      ------------------------------

      unix_timestamp('0000-00-00')

      ------------------------------

      0

      ------------------------------
      1 row in set (0.00 sec)

      Attachments

        Activity

          People

            Unassigned Unassigned
            sergiytytarenko Sergiy Tytarenko (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 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.