My Oracle Support Banner

MySQL 5.5, 5.6, and 5.7: Wrong Result With UTF-8 and UNION Between User Variable and Decimal Column (Doc ID 2404233.1)

Last updated on MAY 28, 2018

Applies to:

MySQL Server - Version 5.5 to 5.7 [Release 5.5 to 5.7]
Information in this document applies to any platform.

Symptoms

In MySQL 5.5, 5.6, or 5.7 using the utf8 or utf8mb4 character set and executing a query that uses a union between a user variable and a decimal value, the result is not correct if the value of the user variable is greater than 99999 (utf8) or 9999 (utf8mb4). For example:

 

Changes

The issue may have started after upgrading to MySQL 5.5 or later or after changing the default character set.

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.