You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-08-01 06:46:55 +03:00
Merge branch 'stable-23.10' into MCOL-4240
This commit is contained in:
@ -761,7 +761,7 @@ int ProcessDDLStatement(string& ddlStatement, string& schema, const string& /*ta
|
||||
#ifdef MCS_DEBUG
|
||||
cout << "ProcessDDLStatement: " << schema << "." << table << ":" << ddlStatement << endl;
|
||||
#endif
|
||||
|
||||
|
||||
parser.setDefaultSchema(schema);
|
||||
parser.setDefaultCharset(default_table_charset);
|
||||
int rc = 0;
|
||||
@ -2205,24 +2205,34 @@ int ProcessDDLStatement(string& ddlStatement, string& schema, const string& /*ta
|
||||
|
||||
if (ddlStatement.find("AUTO_INCREMENT") != string::npos)
|
||||
{
|
||||
thd->raise_error_printf(ER_CHECK_NOT_IMPLEMENTED,
|
||||
"Use of the MySQL auto_increment syntax is not supported in Columnstore. If "
|
||||
"you wish to create an auto increment column in Columnstore, please consult "
|
||||
"the Columnstore SQL Syntax Guide for the correct usage.");
|
||||
ci->alterTableState = cal_connection_info::NOT_ALTER;
|
||||
ci->isAlter = false;
|
||||
thd->raise_error_printf(ER_CHECK_NOT_IMPLEMENTED, "The syntax auto_increment is not supported in Columnstore. Please check the Columnstore syntax guide for supported syntax or data types.");
|
||||
}
|
||||
else if(ddlStatement.find("RENAME COLUMN") != string::npos)
|
||||
{
|
||||
thd->raise_error_printf(ER_CHECK_NOT_IMPLEMENTED, "The syntax rename column is not supported by Columnstore. Please check the Columnstore syntax guide for supported syntax or data types.");
|
||||
}
|
||||
else if(ddlStatement.find("MAX_ROWS") != string::npos || ddlStatement.find("MIN_ROWS") != string::npos)
|
||||
{
|
||||
thd->raise_error_printf(ER_CHECK_NOT_IMPLEMENTED, "The syntax min_rows/max_rows is not supported by Columnstore. Please check the Columnstore syntax guide for supported syntax or data types.");
|
||||
}
|
||||
else if(ddlStatement.find("REPLACE TABLE") != string::npos)
|
||||
{
|
||||
thd->raise_error_printf(ER_CHECK_NOT_IMPLEMENTED, "The syntax replace table is not supported by Columnstore. Please check the Columnstore syntax guide for supported syntax or data types.");
|
||||
}
|
||||
else if(ddlStatement.find("DROP COLUMN IF EXISTS") != string::npos)
|
||||
{
|
||||
thd->raise_error_printf(ER_CHECK_NOT_IMPLEMENTED, "The syntax drop column if exists is not supported by Columnstore. Please check the Columnstore syntax guide for supported syntax or data types.");
|
||||
}
|
||||
else
|
||||
{
|
||||
//@Bug 1888,1885. update error message
|
||||
thd->raise_error_printf(ER_CHECK_NOT_IMPLEMENTED,
|
||||
"The syntax or the data type(s) is not supported by Columnstore. Please check "
|
||||
"the Columnstore syntax guide for supported syntax or data types.");
|
||||
ci->alterTableState = cal_connection_info::NOT_ALTER;
|
||||
ci->isAlter = false;
|
||||
thd->raise_error_printf(ER_CHECK_NOT_IMPLEMENTED, "The syntax or the data type(s) is not supported by Columnstore. Please check the Columnstore syntax guide for supported syntax or data types.");
|
||||
}
|
||||
}
|
||||
|
||||
ci->alterTableState = cal_connection_info::NOT_ALTER;
|
||||
ci->isAlter = false;
|
||||
}
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
@ -202,7 +202,7 @@ static int is_columnstore_extents_fill(THD* thd, TABLE_LIST* tables, COND* cond)
|
||||
TABLE* table = tables->table;
|
||||
|
||||
BRM::DBRM::refreshShmWithLock();
|
||||
BRM::DBRM* emp = new BRM::DBRM();
|
||||
std::unique_ptr<BRM::DBRM> emp(new BRM::DBRM());
|
||||
|
||||
if (!emp || !emp->isDBRMReady())
|
||||
{
|
||||
@ -224,7 +224,7 @@ static int is_columnstore_extents_fill(THD* thd, TABLE_LIST* tables, COND* cond)
|
||||
if (strcasecmp(item_field->field_name.str, "object_id") == 0)
|
||||
{
|
||||
cond_oid = fitem->arguments()[1]->val_int();
|
||||
return generate_result(cond_oid, emp, table, thd);
|
||||
return generate_result(cond_oid, emp.get(), table, thd);
|
||||
}
|
||||
}
|
||||
else if (fitem->arguments()[1]->real_item()->type() == Item::FIELD_ITEM &&
|
||||
@ -236,7 +236,7 @@ static int is_columnstore_extents_fill(THD* thd, TABLE_LIST* tables, COND* cond)
|
||||
if (strcasecmp(item_field->field_name.str, "object_id") == 0)
|
||||
{
|
||||
cond_oid = fitem->arguments()[0]->val_int();
|
||||
return generate_result(cond_oid, emp, table, thd);
|
||||
return generate_result(cond_oid, emp.get(), table, thd);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -250,7 +250,7 @@ static int is_columnstore_extents_fill(THD* thd, TABLE_LIST* tables, COND* cond)
|
||||
for (unsigned int i = 1; i < fitem->argument_count(); i++)
|
||||
{
|
||||
cond_oid = fitem->arguments()[i]->val_int();
|
||||
int result = generate_result(cond_oid, emp, table, thd);
|
||||
int result = generate_result(cond_oid, emp.get(), table, thd);
|
||||
|
||||
if (result)
|
||||
return 1;
|
||||
@ -266,7 +266,7 @@ static int is_columnstore_extents_fill(THD* thd, TABLE_LIST* tables, COND* cond)
|
||||
|
||||
while (ss >> cond_oid)
|
||||
{
|
||||
int ret = generate_result(cond_oid, emp, table, thd);
|
||||
int ret = generate_result(cond_oid, emp.get(), table, thd);
|
||||
|
||||
if (ret)
|
||||
return 1;
|
||||
@ -282,7 +282,7 @@ static int is_columnstore_extents_fill(THD* thd, TABLE_LIST* tables, COND* cond)
|
||||
|
||||
for (BRM::OID_t oid = 3000; oid <= MaxOID; oid++)
|
||||
{
|
||||
int result = generate_result(oid, emp, table, thd);
|
||||
int result = generate_result(oid, emp.get(), table, thd);
|
||||
|
||||
if (result)
|
||||
return 1;
|
||||
|
@ -216,7 +216,7 @@ static int generate_result(BRM::OID_t oid, BRM::DBRM* emp, TABLE* table, THD* th
|
||||
static int is_columnstore_files_fill(THD* thd, TABLE_LIST* tables, COND* cond)
|
||||
{
|
||||
BRM::DBRM::refreshShmWithLock();
|
||||
BRM::DBRM* emp = new BRM::DBRM();
|
||||
std::unique_ptr<BRM::DBRM> emp(new BRM::DBRM());
|
||||
BRM::OID_t cond_oid = 0;
|
||||
TABLE* table = tables->table;
|
||||
|
||||
@ -240,7 +240,7 @@ static int is_columnstore_files_fill(THD* thd, TABLE_LIST* tables, COND* cond)
|
||||
if (strcasecmp(item_field->field_name.str, "object_id") == 0)
|
||||
{
|
||||
cond_oid = fitem->arguments()[1]->val_int();
|
||||
return generate_result(cond_oid, emp, table, thd);
|
||||
return generate_result(cond_oid, emp.get(), table, thd);
|
||||
}
|
||||
}
|
||||
else if (fitem->arguments()[1]->real_item()->type() == Item::FIELD_ITEM &&
|
||||
@ -252,7 +252,7 @@ static int is_columnstore_files_fill(THD* thd, TABLE_LIST* tables, COND* cond)
|
||||
if (strcasecmp(item_field->field_name.str, "object_id") == 0)
|
||||
{
|
||||
cond_oid = fitem->arguments()[0]->val_int();
|
||||
return generate_result(cond_oid, emp, table, thd);
|
||||
return generate_result(cond_oid, emp.get(), table, thd);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -266,7 +266,7 @@ static int is_columnstore_files_fill(THD* thd, TABLE_LIST* tables, COND* cond)
|
||||
for (unsigned int i = 1; i < fitem->argument_count(); i++)
|
||||
{
|
||||
cond_oid = fitem->arguments()[i]->val_int();
|
||||
int result = generate_result(cond_oid, emp, table, thd);
|
||||
int result = generate_result(cond_oid, emp.get(), table, thd);
|
||||
|
||||
if (result)
|
||||
return 1;
|
||||
@ -282,7 +282,7 @@ static int is_columnstore_files_fill(THD* thd, TABLE_LIST* tables, COND* cond)
|
||||
|
||||
while (ss >> cond_oid)
|
||||
{
|
||||
int ret = generate_result(cond_oid, emp, table, thd);
|
||||
int ret = generate_result(cond_oid, emp.get(), table, thd);
|
||||
|
||||
if (ret)
|
||||
return 1;
|
||||
@ -300,14 +300,13 @@ static int is_columnstore_files_fill(THD* thd, TABLE_LIST* tables, COND* cond)
|
||||
{
|
||||
for (BRM::OID_t oid = 3000; oid <= MaxOID; oid++)
|
||||
{
|
||||
int result = generate_result(oid, emp, table, thd);
|
||||
int result = generate_result(oid, emp.get(), table, thd);
|
||||
|
||||
if (result)
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
delete emp;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user