Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
5.5(EOL), 10.0(EOL), 10.1(EOL), 10.2(EOL), 10.3(EOL), 10.4(EOL)
-
None
Description
CREATE OR REPLACE TABLE t1 (i BIGINT); |
INSERT INTO t1 VALUES (42); |
CREATE OR REPLACE TABLE t2 AS SELECT |
REPEAT(i,0) AS c0, |
REPEAT(i,-1) AS c1 |
FROM t1; |
SHOW CREATE TABLE t2; |
+-------+------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
| Table | Create Table |
|
+-------+------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
| t2 | CREATE TABLE `t2` (
|
`c0` char(0) CHARACTER SET utf8 DEFAULT NULL,
|
`c1` longtext CHARACTER SET utf8 DEFAULT NULL
|
) ENGINE=InnoDB DEFAULT CHARSET=latin1 |
|
+-------+------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
It's expected that c1 also creates a column of the `char(0)` data type.
This problem causes ColumnStore to crash, see MDEV-20085 for details.
Attachments
Issue Links
- blocks
-
MDEV-20085 Negative count causes SQL repeat() to set expected result length to 16MB instead of 0
- Closed
- relates to
-
MDEV-20303 SPACE(-1) returns a wrong data type
- Closed