Bug #101945 | JSON Unsigned Integer out of range for Unsigned Bigint column | ||
---|---|---|---|
Submitted: | 9 Dec 2020 22:03 | Modified: | 10 Dec 2020 5:01 |
Reporter: | Morgan Tocker | Email Updates: | |
Status: | Verified | Impact on me: | |
Category: | MySQL Server: JSON | Severity: | S3 (Non-critical) |
Version: | 5.7.31, 8.0.22 | OS: | Any |
Assigned to: | CPU Architecture: | Any |
[9 Dec 2020 22:03]
Morgan Tocker
[10 Dec 2020 1:40]
Morgan Tocker
This is another variant that is useful to show the issue. I would expect that both cases should work the same: DROP TABLE IF EXISTS t3; CREATE TABLE t3 (a bigint unsigned as (b->"$.a"), b json); INSERT INTO t3 (b) VALUES ('{"a":9223372036854775808}'); # fails INSERT INTO t3 (b) VALUES ('{"a":"9223372036854775808"}'); # fails SELECT * FROM t3; DROP TABLE IF EXISTS t4; CREATE TABLE t4 (a bigint unsigned as (b->>"$.a"), b json); INSERT INTO t4 (b) VALUES ('{"a":9223372036854775808}'); # works INSERT INTO t4 (b) VALUES ('{"a":"9223372036854775808"}'); # works SELECT * FROM t4;
[10 Dec 2020 5:01]
MySQL Verification Team
Hello Morgan, Thank you for the report and feedback. regards, Umesh