stonedb icon indicating copy to clipboard operation
stonedb copied to clipboard

question: create table t4 select * from t3; It is not supported at present, when can it be supported

Open shangyanwen opened this issue 2 years ago • 1 comments

General Question

#Describe the problem

1、create table t3(a int,b char(20))engine=stonedb;
2、insert into t3(b) values("hello"),("my"),("world");
3、create table t4 select * from t3;
ERROR 6 (HY000): The query includes syntax that is not supported by the storage engine. Either restructure the query with supported syntax, or enable the MySQL core::Query Path in config file to execute the query with reduced performance.

#Expected behavior

The StonedB engine supports this,which is a very common feature

shangyanwen avatar Jul 14 '22 08:07 shangyanwen

Stonedb does not support CTAS, but you can execute the following steps: 1、create table t4 like t3; 2、insert into t4 select * from t3;

Also, you can set stonedb's parameter,tianmu_ini_allowmysqlquerypath=1. Then,you must restart the StoneDB instance.

haitaoguan avatar Aug 16 '22 03:08 haitaoguan

the table_list is null

if (with_insert)
    table_list = table_list->next_global;  // we skip one

  if (!table_list)
    return false;

DandreChen avatar Nov 30 '22 07:11 DandreChen

see #1038

DandreChen avatar Dec 01 '22 02:12 DandreChen

The CTAS syntax has supported by StoneDB,You can download the latest version.

haitaoguan avatar Dec 13 '22 02:12 haitaoguan