void CRURefreshTaskExecutor::ComposeControlTableStmtForUsedTable(CRUTbl &tbl, Int32 &stmtIndex, CRUForceOptions::MdamOptions mdamOpt) { CRURefreshSQLComposer myComposer(GetRefreshTask()); if (CRUForceOptions::MDAM_NO_FORCE == mdamOpt) { CRUTableForceOptions *forceOpt = GetForceOptionForTable(tbl.GetFullName()); if (NULL == forceOpt) { mdamOpt = GetDefaultMdamOptForTable(tbl); } else { mdamOpt = forceOpt->GetMdamOptions(); } } if (CRUForceOptions::MDAM_NO_FORCE != mdamOpt) { // Compose CONTROL TABLE table_name MDAM option myComposer.ComposeCntrlTableMDAMText(mdamOpt, &(tbl.GetFullName())); pRefreshTEDynamicContainer_->SetStatementText #pragma nowarn(1506) // warning elimination (stmtIndex++, myComposer.GetSQL()); #pragma warn(1506) // warning elimination forceFlags_ |= FORCE_TABLE_MDAM; } }
CRUForceOptions::MdamOptions CRUMVForceOptions::GetForceMdamOptionForTable(const CDSString& tableName) const { DSListPosition pos = pTablesList_->GetHeadPosition(); while (NULL != pos) { CRUTableForceOptions* aTable = pTablesList_-> GetNext(pos); if (tableName == aTable->GetFullName()) { return aTable->GetMdamOptions(); } } return CRUForceOptions::MDAM_NO_FORCE; }
CRUTableForceOptions::CRUTableForceOptions(const CRUTableForceOptions& srcTbl) { tableName_ = srcTbl.GetFullName(); mdam_ = srcTbl.GetMdamOptions(); }