Details
-
Bug
-
Status: Confirmed (View Workflow)
-
Major
-
Resolution: Unresolved
-
11.4, 11.8, 12.3, 13.1
-
None
Description
Hi,
The following test case triggers an unexpected error `ERROR 1406 (22001) at line 8: Data too long for column 'c' at row 1`, however, the length of row 1 is only 53:
SELECT JSON_KEY_VALUE('{"a":1,"b":22}', '$') AS direct_value, |
CHAR_LENGTH(JSON_KEY_VALUE('{"a":1,"b":22}', '$')) AS direct_len; |
-- [{"key": "a", "value": 1}, {"key": "b", "value": 22}] 53
|
 |
CREATE TABLE t_key AS |
SELECT JSON_KEY_VALUE('{"a":1,"b":22}', '$') AS c; |
-- ERROR 1406 (22001) at line 8: Data too long for column 'c' at row 1 |