Details
-
Bug
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
None
-
None
-
None
-
Customer repro on 22.08.3
SkySQL Server version: 10.6.7-3-MariaDB-enterprise-log MariaDB Enterprise Server
Description
Using Alter table like make it look like a temporary table was created:
MariaDB [(none)]> use test;
Database changed
MariaDB [test]> CREATE TABLE columnstore_table (
-> orderkey INTEGER,
-> customer VARCHAR(45)
-> ) ENGINE=ColumnStore;
Query OK, 0 rows affected (0.250 sec)
MariaDB [test]> show tables;
-------------------
Tables_in_test |
-------------------
columnstore_table |
-------------------
1 row in set (0.017 sec)
show create table columnstore_table;
Table | Create Table |
columnstore_table | CREATE TABLE `columnstore_table` ( `orderkey` int(11) DEFAULT NULL, `customer` varchar(45) DEFAULT NULL ) ENGINE=Columnstore DEFAULT CHARSET=utf8mb3 |
1 row in set (0.015 sec)
MariaDB [test]> CREATE TEMPORARY TABLE temp1 LIKE test.columnstore_table;
Query OK, 0 rows affected (0.226 sec)
MariaDB [test]> show create table temp1;
Table | Create Table |
temp1 | CREATE TEMPORARY TABLE `temp1` ( `orderkey` int(11) DEFAULT NULL, `customer` varchar(45) DEFAULT NULL ) ENGINE=Columnstore DEFAULT CHARSET=utf8mb3 |
1 row in set (0.015 sec)
MariaDB [test]> ALTER TABLE test.temp1 ENGINE = InnoDB;
Query OK, 0 rows affected (0.089 sec)
Records: 0 Duplicates: 0 Warnings: 0
MariaDB [test]> show create table temp1;
MariaDB [test]> ALTER TABLE test.temp1 ENGINE = InnoDB;
Query OK, 0 rows affected (0.089 sec)
Records: 0 Duplicates: 0 Warnings: 0
MariaDB [test]> show create table temp1;
Table | Create Table |
temp1 | CREATE TEMPORARY TABLE `temp1` ( `orderkey` int(11) DEFAULT NULL, `customer` varchar(45) DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 |
1 row in set (0.015 sec)
MariaDB [test]> DROP TEMPORARY TABLE temp1;
Query OK, 0 rows affected (0.015 sec)
MariaDB [test]> CREATE TEMPORARY TABLE temp1 LIKE test.columnstore_table;
ERROR 1815 (HY000): Internal error: CAL0009: Internal create table error for test.temp1 : table already exists (your schema is probably out-of-sync)