Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 5.1.67, 5.2.14, 5.3.12, 5.5.36, 10.0.10
    • Fix Version/s: 5.3.13, 10.0, 5.5
    • Component/s: None
    • Labels:

      Description

      select round(1e308/3,-302);
      +----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
      | round(1e308/3,-302)                                                                                                                                                                                                                                                                                                  |
      +----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
      | 33333300000000004000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 |
      +----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
      1 row in set (0.00 sec)
      

      The above result is wrong: notice digit "4" after some zeros.
      It should be "0" at this position.

        Gliffy Diagrams

          Attachments

            Activity

            Hide
            elenst Elena Stepanova added a comment -

            MySQL 5.5-5.7 are also affected.
            MariaDB 5.1-5.3 return an essentially different result (not just one digit off).

            Show
            elenst Elena Stepanova added a comment - MySQL 5.5-5.7 are also affected. MariaDB 5.1-5.3 return an essentially different result (not just one digit off).

              People

              • Assignee:
                bar Alexander Barkov
                Reporter:
                bar Alexander Barkov
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated: