Details
-
Bug
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
5.5.1
-
None
-
debian 9
Description
when performed without using cpimport, insert into ... select ... statements corrupt the columnstore table catalog. the columnstore plugin needs to be restarted for the table to work normally
-- 1. create a columnstore table
|
create table t(a int) engine=ColumnStore; |
|
-- 2. fill table with insert .. select without using cpimport
|
set statement columnstore_use_import_for_batchinsert=off for |
insert into t(a) |
select 1; |
|
-- 3. t exists, seems to works fine
|
select count(*) from t; /* returns 1 */ |
|
-- 4. when t is renamed, it turns out t was somehow corrupted
|
rename table t to t2; |
select count(*) from t2; /* returns Error Code: 1815. Internal error: IDB-2006: 'mydb.t2' does not exist in Columnstore */ |
|
-- 5. after systemctl restart mariadb-columnstore, t2 works normally
|
select count(*) from t2; /* returns 1 */ |
|
- the problem does not appear when using columnstore_use_import_for_batchinsert=on (but using cpimport comes with its own issues, reported separately)
- the problem does not appear with insert into ... values (). it is specifically about insert into ... select
- the problem does not seem to be linked with the rename command. If the columnstore is restarted before step 4 then the rename actually works fine