View Revisions: Issue #17361

Summary 17361: upgrade from 3.14.6 to version 5.0.3 fails for missing table
Revision 2021-06-09 14:56 by ollehar
Description The database update from 3.14.6. to 5.0.3 fails because missing table SurveysGroupsettings

CDbException
La table « {{surveys_groupsettings}} » associée à la classe Active record « SurveysGroupsettings » est introuvable dans la base de données.

/data/www/limesurvey2-lab/framework/db/ar/CActiveRecord.php(2390)

2378
2379 /**
2380 * Constructor.
2381 * @param CActiveRecord $model the model instance
2382 * @throws CDbException if specified table for active record class cannot be found in the database
2383 */
2384 public function __construct($model)
2385 {
2386 $this->_modelClassName=get_class($model);
2387
2388 $tableName=$model->tableName();
2389 if(($table=$model->getDbConnection()->getSchema()->getTable($tableName))===null)
2390 throw new CDbException(Yii::t('yii','The table "{table}" for active record class "{class}" cannot be found in the database.',
2391 array('{class}'=>$this->_modelClassName,'{table}'=>$tableName)));
2392
2393 if(($modelPk=$model->primaryKey())!==null || $table->primaryKey===null)
2394 {
2395 $table->primaryKey=$modelPk;
2396 if(is_string($table->primaryKey) && isset($table->columns[$table->primaryKey]))
2397 $table->columns[$table->primaryKey]->isPrimaryKey=true;
2398 elseif(is_array($table->primaryKey))
2399 {
2400 foreach($table->primaryKey as $name)
2401 {
2402 if(isset($table->columns[$name]))
Revision 2021-06-09 14:39 by yniquet
Description The database update from 3.14.6. to 5.0.3 fails because missing table SurveysGroupsettings

CDbException
La table « {{surveys_groupsettings}} » associée à la classe Active record « SurveysGroupsettings » est introuvable dans la base de données.

/data/www/limesurvey2-lab/framework/db/ar/CActiveRecord.php(2390)

2378
2379 /**
2380 * Constructor.
2381 * @param CActiveRecord $model the model instance
2382 * @throws CDbException if specified table for active record class cannot be found in the database
2383 */
2384 public function __construct($model)
2385 {
2386 $this->_modelClassName=get_class($model);
2387
2388 $tableName=$model->tableName();
2389 if(($table=$model->getDbConnection()->getSchema()->getTable($tableName))===null)
2390 throw new CDbException(Yii::t('yii','The table "{table}" for active record class "{class}" cannot be found in the database.',
2391 array('{class}'=>$this->_modelClassName,'{table}'=>$tableName)));
2392
2393 if(($modelPk=$model->primaryKey())!==null || $table->primaryKey===null)
2394 {
2395 $table->primaryKey=$modelPk;
2396 if(is_string($table->primaryKey) && isset($table->columns[$table->primaryKey]))
2397 $table->columns[$table->primaryKey]->isPrimaryKey=true;
2398 elseif(is_array($table->primaryKey))
2399 {
2400 foreach($table->primaryKey as $name)
2401 {
2402 if(isset($table->columns[$name]))