Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
10.1(EOL), 10.2(EOL), 10.3(EOL)
Description
SET sql_mode=STRICT_ALL_TABLES;
|
CREATE OR REPLACE TABLE t1 (a INT UNSIGNED NOT NULL);
|
INSERT INTO t1 VALUES (0xFFFFFFFF);
|
CREATE OR REPLACE TABLE t2 AS SELECT a+1 FROM t1;
|
ERROR 1264 (22003): Out of range value for column 'a+1' at row 1
|
Adding LIMIT 0 shows that an INT(11) instead of a BITINT(11) column is created:
CREATE OR REPLACE TABLE t2 AS SELECT a+1 FROM t1 LIMIT 0; |
DESCRIBE t2;
|
+-------+------------------+------+-----+---------+-------+
|
| Field | Type | Null | Key | Default | Extra |
|
+-------+------------------+------+-----+---------+-------+
|
| a+1 | int(11) unsigned | NO | | 0 | |
|
+-------+------------------+------+-----+---------+-------+
|
Attachments
Issue Links
- blocks
-
MDEV-4912 Data type plugin API version 1
- Closed
- relates to
-
MDEV-12854 Synchronize CREATE..SELECT data type and result set metadata data type for INT functions
- Closed
-
MDEV-12857 Out-of-range errors on CREATE..SELECT 2222222222 DIV 1
- Closed
-
MDEV-12859 Out-of-range error for CREATE..SELECT @a:=EXTRACT(MINUTE_MICROSECOND FROM..)
- Closed
-
MDEV-12860 Out-of-range error on CREATE..SELECT with a view using MAX and EXTRACT(MINUTE_MICROSECOND..)
- Closed
-
MDEV-14910 Unexpected "BIGINT UNSIGNED value is out of range" for minus
- Open