本文整理汇总了C++中Driver::DropAllSpecTables方法的典型用法代码示例。如果您正苦于以下问题:C++ Driver::DropAllSpecTables方法的具体用法?C++ Driver::DropAllSpecTables怎么用?C++ Driver::DropAllSpecTables使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Driver
的用法示例。
在下文中一共展示了Driver::DropAllSpecTables方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: QueryResponse
void UnitCfg::QueryResponse (QObject *p, const QString &c, int State, QObject*caller) // notify transaction completerequestrt needs the name record addedivityLled int2);, tion text,repprint int2);ate text);
{
if(p != this) return;
IT_IT("UnitCfg::QueryResponse");
switch (State)
{
case tList:
{
// fill the name list box
GetConfigureDb ()->FillComboBox (Name, "NAME");
Name->setCurrentItem (0);
SelChanged (0);
Name->setFocus ();
ButtonState (true);
};
break;
case tItem:
{
IT_COMMENT("Received User Data");
// fill the fields
Comment->setText (UndoEscapeSQLText(GetConfigureDb()->GetString ("COMMENT")));
SetComboItem (UnitType, GetConfigureDb ()->GetString ("UNITTYPE"));
Enabled->setChecked (GetConfigureDb ()->GetString ("ENABLED").toInt ());
Comment->setFocus ();
ButtonState (true);
};
break;
case tDrop:
{
int n = GetConfigureDb()->GetNumberResults();
QStringList list;
QString point_list = "(";
if (n)
{
for(int i = 0; i < n; i++,GetConfigureDb()->FetchNext())
{
if(i)
{
point_list += ",";
};
point_list += "'" + GetConfigureDb()->GetString("NAME") + "'";
//
list << GetConfigureDb()->GetString ("NAME");
};
point_list += ");";
}
QString cmd ="delete from TAGS_DB where NAME in " + point_list;
GetCurrentDb ()->DoExec (0,cmd,0);
//
cmd ="delete from CVAL_DB where NAME in " + point_list;
GetCurrentDb ()->DoExec (0,cmd,0);
if(!list.isEmpty())
{
QStringList::Iterator it = list.begin();
for(;it != list.end();++it)
{
QString cmd = "drop table "+ (*it) + ";";
GetResultDb()->DoExec(0,cmd,0);
}
}
//TO DO APA caricare tutti i Driver *p in un dizionario come fa il monitor
//e poi usarli quando e' necessario
Driver * p = FindDriver(UnitType->currentText());
if(p)
{
DOAUDIT(tr("Drop Unit Tables:") + Name->currentText());
p->DropAllSpecTables(list); // invoked the unit level drop tables
}
}
break;
case tNew:
case tDelete:
case tApply:
ButtonState (true);
default:
break;
};
};