You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-07-30 19:23:07 +03:00
MCOL-5021 Add support for the AUX column in TRUNCATE table processing.
This commit is contained in:
@ -779,6 +779,7 @@ TruncTableProcessor::DDLResult TruncTableProcessor::processPackage(
|
|||||||
|
|
||||||
std::vector<CalpontSystemCatalog::OID> columnOidList;
|
std::vector<CalpontSystemCatalog::OID> columnOidList;
|
||||||
std::vector<CalpontSystemCatalog::OID> allOidList;
|
std::vector<CalpontSystemCatalog::OID> allOidList;
|
||||||
|
CalpontSystemCatalog::OID tableAuxColOid;
|
||||||
CalpontSystemCatalog::RIDList tableColRidList;
|
CalpontSystemCatalog::RIDList tableColRidList;
|
||||||
CalpontSystemCatalog::DictOIDList dictOIDList;
|
CalpontSystemCatalog::DictOIDList dictOIDList;
|
||||||
execplan::CalpontSystemCatalog::ROPair roPair;
|
execplan::CalpontSystemCatalog::ROPair roPair;
|
||||||
@ -919,6 +920,7 @@ TruncTableProcessor::DDLResult TruncTableProcessor::processPackage(
|
|||||||
userTableName.table = truncTableStmt.fTableName->fName;
|
userTableName.table = truncTableStmt.fTableName->fName;
|
||||||
|
|
||||||
tableColRidList = systemCatalogPtr->columnRIDs(userTableName);
|
tableColRidList = systemCatalogPtr->columnRIDs(userTableName);
|
||||||
|
tableAuxColOid = systemCatalogPtr->tableAUXColumnOID(userTableName);
|
||||||
|
|
||||||
dictOIDList = systemCatalogPtr->dictOIDs(userTableName);
|
dictOIDList = systemCatalogPtr->dictOIDs(userTableName);
|
||||||
|
|
||||||
@ -931,6 +933,12 @@ TruncTableProcessor::DDLResult TruncTableProcessor::processPackage(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (tableAuxColOid > 3000)
|
||||||
|
{
|
||||||
|
columnOidList.push_back(tableAuxColOid);
|
||||||
|
allOidList.push_back(tableAuxColOid);
|
||||||
|
}
|
||||||
|
|
||||||
for (unsigned i = 0; i < dictOIDList.size(); i++)
|
for (unsigned i = 0; i < dictOIDList.size(); i++)
|
||||||
{
|
{
|
||||||
if (dictOIDList[i].dictOID > 3000)
|
if (dictOIDList[i].dictOID > 3000)
|
||||||
|
@ -5843,6 +5843,10 @@ void CalpontSystemCatalog::flushCache()
|
|||||||
buildSysTablemap();
|
buildSysTablemap();
|
||||||
lk3.unlock();
|
lk3.unlock();
|
||||||
|
|
||||||
|
boost::mutex::scoped_lock namemaplk(fTableNameMapLock);
|
||||||
|
fTableNameMap.clear();
|
||||||
|
namemaplk.unlock();
|
||||||
|
|
||||||
boost::mutex::scoped_lock auxlk(fTableAUXColumnOIDMapLock);
|
boost::mutex::scoped_lock auxlk(fTableAUXColumnOIDMapLock);
|
||||||
fTableAUXColumnOIDMap.clear();
|
fTableAUXColumnOIDMap.clear();
|
||||||
auxlk.unlock();
|
auxlk.unlock();
|
||||||
|
Reference in New Issue
Block a user