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

Wrong result of MAKETIME(0, 0, -0.1)

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Minor
    • Resolution: Duplicate
    • 10.0.3, 5.5.32, 5.3.12
    • 10.0.5, 5.5.33, 5.3.13
    • None
    • None

    Description

      There is some inconsistency between
      MAKETIME(0,0, negative_integer_number) and
      MAKETIME(0,0, negative_decimal_number)

      SELECT MAKETIME(0,0,-1), MAKETIME(0, 0, -0.1);
      +------------------+----------------------+
      | MAKETIME(0,0,-1) | MAKETIME(0, 0, -0.1) |
      +------------------+----------------------+
      | NULL             | 00:00:00             |
      +------------------+----------------------+

      The expression with the negative decimal number should also return NULL.

      MySQL-5.5 exhibits the same behaviour.
      MySQL-5.6 returns NULL for both expressions.

      Attachments

        Activity

          People

            bar Alexander Barkov
            bar Alexander Barkov
            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.