mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2025-10-17 16:11:12 +02:00
2018-07-17 Fred Gleason <fredg@paravelsystems.com>
* Fixed a bug in rddgmgr(8) that would cause an abort if a '_STACK' table was found missing when updating to schema 293.
This commit is contained in:
@@ -371,6 +371,22 @@ void MainObject::WriteSchemaVersion(int ver) const
|
||||
}
|
||||
|
||||
|
||||
bool MainObject::TableExists(const QString &tbl_name) const
|
||||
{
|
||||
QString sql;
|
||||
RDSqlQuery *q;
|
||||
bool ret=false;
|
||||
|
||||
sql=QString("show tables where ")+
|
||||
"Tables_in_"+db_config->mysqlDbname()+"=\""+RDEscapeString(tbl_name)+"\"";
|
||||
q=new RDSqlQuery(sql,false);
|
||||
ret=q->first();
|
||||
delete q;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
bool MainObject::DropTable(const QString &tbl_name,QString *err_msg) const
|
||||
{
|
||||
QString sql;
|
||||
|
Reference in New Issue
Block a user