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

Wrong result for CAST(CONVERT('1IJ3' USING ucs2) AS SIGNED)

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 5.5, 10.0, 10.1, 10.2
    • Fix Version/s: 10.1.10
    • Component/s: Character Sets
    • Labels:
      None

      Description

      mysql> SELECT CAST(CONVERT('1IJ3' USING ucs2) AS SIGNED);
      +--------------------------------------------+
      | CAST(CONVERT('1IJ3' USING ucs2) AS SIGNED)  |
      +--------------------------------------------+
      |                                        123 |
      +--------------------------------------------+
      1 row in set (0.00 sec)

      The above result is wrong. The expected result is 1 with a warning.

      The character:

      U+0132 LATIN CAPITAL LIGATURE IJ

      is misinterpreted as

      U+0032 DIGIT TWO

        Attachments

          Activity

            People

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

              Dates

              Created:
              Updated:
              Resolved:

                Git Integration