View Issue Details

This bug affects 1 person(s).
 4
IDProjectCategoryView StatusLast Update
06867Bug reportsOtherpublic2012-11-16 10:40
Reporterrolandr Assigned Toc_schmitz  
PrioritynormalSeveritypartial_block 
Status closedResolutionfixed 
Product Version2.00+ 
Fixed in Version2.00+ 
Summary06867: modification of user and survey rights result in an error
Description

i installed limesurvey200plus without any problems, i did the update to the newest version. i started to do a test-survey and added one survey-admin.

i've two problems now, both have to do with right management.

first, i cannot set "global rights" for the user i added. when doing so, i get "Error executing query in dbSelectLimitAssoc:SELECT uid FROM lime_users

WHERE parent_id=0".

second, when changing survey rights i receive the following "Internal Server Error - CDbCommand failed to execute the SQL statement: SQLSTATE[HY000]:

General error: 2014 Cannot execute queries while other unbuffered queries are active. Consider using PDOStatement::fetchAll(). Alternatively, if your

code is only ever going to run against mysql, you may enable query buffering by setting the PDO::MYSQL_ATTR_USE_BUFFERED_QUERY attribute."

everything else works normally as far as i tested it now.

Steps To Reproduce

user rights: when clicking on the "set global rights for this user" padlock icon the error results as mentioned above.

survey rights: when clicking on the "set survey rights" padlock icon the error results as mentioned above.

Additional Information

i attached a phpinfo excerpt as pdf.
if you need further information please do not hesitate to contact me. roland@rouschal.com

TagsNo tags attached.
Attached Files
phpinfo.pdf (135,660 bytes)
debug2.txt (10,280 bytes)   
CDbException

CDbCommand failed to execute the SQL statement: SQLSTATE[HY000]: General error: 2014 Cannot execute queries while other unbuffered queries are active. Consider using PDOStatement::fetchAll(). Alternatively, if your code is only ever going to run against mysql, you may enable query buffering by setting the PDO::MYSQL_ATTR_USE_BUFFERED_QUERY attribute.. The SQL statement executed was: SELECT * FROM lime_users ORDER BY uid

/var/www/html/survey/framework/db/CDbCommand.php(528)

516             return $result;
517         }
518         catch(Exception $e)
519         {
520             if($this->_connection->enableProfiling)
521                 Yii::endProfile('system.db.CDbCommand.query('.$this->getText().$par.')','system.db.CDbCommand.query');
522             $errorInfo = $e instanceof PDOException ? $e->errorInfo : null;
523             $message = $e->getMessage();
524             Yii::log(Yii::t('yii','CDbCommand::{method}() failed: {error}. The SQL statement executed was: {sql}.',
525                 array('{method}'=>$method, '{error}'=>$message, '{sql}'=>$this->getText().$par)),CLogger::LEVEL_ERROR,'system.db.CDbCommand');
526             if(YII_DEBUG)
527                 $message .= '. The SQL statement executed was: '.$this->getText().$par;
528             throw new CDbException(Yii::t('yii','CDbCommand failed to execute the SQL statement: {error}',
529                 array('{error}'=>$message)),(int)$e->getCode(),$errorInfo);
530         }
531     }
532 
533     /**
534      * Builds a SQL SELECT statement from the given query specification.
535      * @param array $query the query specification in name-value pairs. The following
536      * query options are supported: {@link select}, {@link distinct}, {@link from},
537      * {@link where}, {@link join}, {@link group}, {@link having}, {@link order},
538      * {@link limit}, {@link offset} and {@link union}.
539      * @return string the SQL statement
540      * @since 1.1.6

Stack Trace
#0 	
�
 /var/www/html/survey/framework/db/CDbCommand.php(372): CDbCommand->queryInternal("", 0, array())

367      * @return CDbDataReader the reader object for fetching the query result
368      * @throws CException execution failed
369      */
370     public function query($params=array())
371     {
372         return $this->queryInternal('',0,$params);
373     }
374 
375     /**
376      * Executes the SQL statement and returns all rows.
377      * @param boolean $fetchAssociative whether each row should be returned as an associated array with

#1 	
�
 /var/www/html/survey/application/helpers/common_helper.php(1342): CDbCommand->query()

1337     else
1338     {
1339         $uquery = "SELECT * FROM {{users}} ORDER BY uid";
1340     }
1341 
1342     $uresult = Yii::app()->db->createCommand($uquery)->query()->readAll(); //Checked
1343 
1344     if (count($uresult)==0)
1345     //user is not in a group and usercontrolSameGroupPolicy is activated - at least show his own userinfo
1346     {
1347         $uquery = "SELECT u.* FROM {{users}} AS u WHERE u.uid=".$myuid;

#2 	
�
 /var/www/html/survey/application/helpers/common_helper.php(7561): getUserList()

7556     $surveyselecter = "";
7557 
7558     if (Yii::app()->getConfig('usercontrolSameGroupPolicy') == true)
7559     {
7560 
7561         $authorizedUsersList = getUserList('onlyuidarray');
7562     }
7563 
7564         foreach($surveyidresult->readAll() as $sv)
7565         {
7566             if (Yii::app()->getConfig('usercontrolSameGroupPolicy') == false ||

#3 	
�
 /var/www/html/survey/application/controllers/admin/surveypermission.php(169): getSurveyUserList()

164 
165             $surveysecurity .= "</tbody>\n"
166             . "</table>\n"
167             . "<form class='form44' action='".$this->getController()->createUrl('admin/surveypermission/adduser/surveyid/'.$surveyid)."' method='post'><ul>\n"
168             . "<li><label for='uidselect'>".$clang->gT("User").": </label><select id='uidselect' name='uid'>\n"
169             . getSurveyUserList(false,false,$surveyid)
170             . "</select>\n"
171             . "<input style='width: 15em;' type='submit' value='".$clang->gT("Add User")."'  onclick=\"if (document.getElementById('uidselect').value == -1) { alert('".$clang->gT("Please select a user first","js")."'); return false;}\"/>"
172             . "<input type='hidden' name='action' value='addsurveysecurity' />"
173             . "</li></ul></form>\n"
174             . "<form class='form44' action='".$this->getController()->createUrl('admin/surveypermission/addusergroup/surveyid/'.$surveyid)."' method='post'><ul><li>\n"

#4 	
 unknown(0): surveypermission->index("onlyuidarray")
#5 	
�
 /var/www/html/survey/framework/web/actions/CAction.php(107): ReflectionMethod->invokeArgs(false, false, "428269")

102             else if($param->isDefaultValueAvailable())
103                 $ps[]=$param->getDefaultValue();
104             else
105                 return false;
106         }
107         $method->invokeArgs($object,$ps);
108         return true;
109     }
110 }

#6 	
�
 /var/www/html/survey/application/core/Survey_Common_Action.php(82): CAction->runWithParamsInternal("428269")

77             $oMethod = new ReflectionMethod($this, $sDefault);
78         }
79 
80         // We're all good to go, let's execute it
81         // runWithParamsInternal would automatically get the parameters of the method and populate them as required with the params
82         return parent::runWithParamsInternal($this, $oMethod, $params);
83     }
84 
85     /**
86     * Some functions have different parameters, which are just an alias of the
87     * usual parameters we're getting in the url. This function just populates

#7 	
�
 /var/www/html/survey/framework/web/CController.php(309): Survey_Common_Action->runWithParams(surveypermission, array("428269"))

304     {
305         $priorAction=$this->_action;
306         $this->_action=$action;
307         if($this->beforeAction($action))
308         {
309             if($action->runWithParams($this->getActionParams())===false)
310                 $this->invalidActionParams($action);
311             else
312                 $this->afterAction($action);
313         }
314         $this->_action=$priorAction;

#8 	
�
 /var/www/html/survey/framework/web/CController.php(287): CController->runAction(surveypermission, ReflectionMethod, array("surveyid" => "428269", "sa" => "view", "iSurveyId" => "428269", "iSurveyID" => "428269"))

282      * @see runAction
283      */
284     public function runActionWithFilters($action,$filters)
285     {
286         if(empty($filters))
287             $this->runAction($action);
288         else
289         {
290             $priorAction=$this->_action;
291             $this->_action=$action;
292             CFilterChain::create($this,$action,$filters)->run();

#9 	
�
 /var/www/html/survey/framework/web/CController.php(266): CController->runActionWithFilters(array("surveyid" => "428269", "sa" => "view"))

261         {
262             if(($parent=$this->getModule())===null)
263                 $parent=Yii::app();
264             if($parent->beforeControllerAction($this,$action))
265             {
266                 $this->runActionWithFilters($action,$this->filters());
267                 $parent->afterControllerAction($this,$action);
268             }
269         }
270         else
271             $this->missingAction($actionID);

#10 	
�
 /var/www/html/survey/application/controllers/AdminController.php(159): CController->run(surveypermission)

154                 Yii::app()->session['redirectopage'] = Yii::app()->request->requestUri;
155 
156                 $this->redirect($this->createUrl('/admin/authentication/login'));
157             }
158 
159             return parent::run($action);
160     }
161 
162     /**
163     * Routes all the actions to their respective places
164     *

#11 	
�
 /var/www/html/survey/framework/web/CWebApplication.php(276): AdminController->run(surveypermission, array())

271         {
272             list($controller,$actionID)=$ca;
273             $oldController=$this->_controller;
274             $this->_controller=$controller;
275             $controller->init();
276             $controller->run($actionID);
277             $this->_controller=$oldController;
278         }
279         else
280             throw new CHttpException(404,Yii::t('yii','Unable to resolve the request "{route}".',
281                 array('{route}'=>$route===''?$this->defaultController:$route)));

#12 	
�
 /var/www/html/survey/framework/web/CWebApplication.php(135): CWebApplication->runController("surveypermission")

130             foreach(array_splice($this->catchAllRequest,1) as $name=>$value)
131                 $_GET[$name]=$value;
132         }
133         else
134             $route=$this->getUrlManager()->parseUrl($this->getRequest());
135         $this->runController($route);
136     }
137 
138     /**
139      * Registers the core application components.
140      * This method overrides the parent implementation by registering additional core components.

#13 	
�
 /var/www/html/survey/framework/base/CApplication.php(162): CWebApplication->processRequest("surveypermission")

157      */
158     public function run()
159     {
160         if($this->hasEventHandler('onBeginRequest'))
161             $this->onBeginRequest(new CEvent($this));
162         $this->processRequest();
163         if($this->hasEventHandler('onEndRequest'))
164             $this->onEndRequest(new CEvent($this));
165     }
166 
167     /**

#14 	
�
 /var/www/html/survey/index.php(178): CApplication->run("admin/surveypermission/sa/view")

173  *
174  */
175 require_once BASEPATH . 'yii' . EXT;
176 require_once APPPATH . 'core/LSYii_Application' . EXT;
177 
178 Yii::createApplication('LSYii_Application', APPPATH . 'config/config' . EXT)->run();
179 
180 /* End of file index.php */
181 /* Location: ./index.php */

2012-11-14 11:32:44 Apache Yii Framework/1.1.10
debug2.txt (10,280 bytes)   
debug2_after_changeset.txt (10,779 bytes)   
CDbException

CDbCommand failed to execute the SQL statement: SQLSTATE[HY000]: General error: 2014 Cannot execute queries while other unbuffered queries are active. Consider using PDOStatement::fetchAll(). Alternatively, if your code is only ever going to run against mysql, you may enable query buffering by setting the PDO::MYSQL_ATTR_USE_BUFFERED_QUERY attribute.. The SQL statement executed was: SELECT a.ugid, a.name, a.owner_id, b.uid FROM lime_user_groups AS a LEFT JOIN lime_user_in_groups AS b ON a.ugid = b.ugid WHERE uid = 1 ORDER BY name

/var/www/html/survey/framework/db/CDbCommand.php(528)

516             return $result;
517         }
518         catch(Exception $e)
519         {
520             if($this->_connection->enableProfiling)
521                 Yii::endProfile('system.db.CDbCommand.query('.$this->getText().$par.')','system.db.CDbCommand.query');
522             $errorInfo = $e instanceof PDOException ? $e->errorInfo : null;
523             $message = $e->getMessage();
524             Yii::log(Yii::t('yii','CDbCommand::{method}() failed: {error}. The SQL statement executed was: {sql}.',
525                 array('{method}'=>$method, '{error}'=>$message, '{sql}'=>$this->getText().$par)),CLogger::LEVEL_ERROR,'system.db.CDbCommand');
526             if(YII_DEBUG)
527                 $message .= '. The SQL statement executed was: '.$this->getText().$par;
528             throw new CDbException(Yii::t('yii','CDbCommand failed to execute the SQL statement: {error}',
529                 array('{error}'=>$message)),(int)$e->getCode(),$errorInfo);
530         }
531     }
532 
533     /**
534      * Builds a SQL SELECT statement from the given query specification.
535      * @param array $query the query specification in name-value pairs. The following
536      * query options are supported: {@link select}, {@link distinct}, {@link from},
537      * {@link where}, {@link join}, {@link group}, {@link having}, {@link order},
538      * {@link limit}, {@link offset} and {@link union}.
539      * @return string the SQL statement
540      * @since 1.1.6

Stack Trace
#0 	
�
 /var/www/html/survey/framework/db/CDbCommand.php(372): CDbCommand->queryInternal("", 0, array())

367      * @return CDbDataReader the reader object for fetching the query result
368      * @throws CException execution failed
369      */
370     public function query($params=array())
371     {
372         return $this->queryInternal('',0,$params);
373     }
374 
375     /**
376      * Executes the SQL statement and returns all rows.
377      * @param boolean $fetchAssociative whether each row should be returned as an associated array with

#1 	
�
 /var/www/html/survey/application/helpers/common_helper.php(7130): CDbCommand->query()

7125 {
7126     $clang = Yii::app()->lang;
7127     //$squery = "SELECT ugid, name FROM ".db_table_name('user_groups') ." WHERE owner_id = {Yii::app()->session['loginID']} ORDER BY name";
7128     $squery = "SELECT a.ugid, a.name, a.owner_id, b.uid FROM {{user_groups}} AS a LEFT JOIN {{user_in_groups}} AS b ON a.ugid = b.ugid WHERE uid = ".Yii::app()->session['loginID']." ORDER BY name";
7129 
7130     $sresult = Yii::app()->db->createCommand($squery)->query(); //Checked
7131     if (!$sresult) {return "Database Error";}
7132     $selecter = "";
7133     foreach ($sresult->readAll() as $row)
7134     {
7135         $groupnames[] = $row;

#2 	
�
 /var/www/html/survey/application/helpers/common_helper.php(7610): getUserGroupList()

7605 
7606     $surveyselecter = "";
7607 
7608     if (Yii::app()->getConfig('usercontrolSameGroupPolicy') == true)
7609     {
7610         $authorizedGroupsList=getUserGroupList(NULL, 'simplegidarray');
7611     }
7612 
7613     foreach($surveyidresult->readAll() as $sv)
7614     {
7615         if (Yii::app()->getConfig('usercontrolSameGroupPolicy') == false ||

#3 	
�
 /var/www/html/survey/application/controllers/admin/surveypermission.php(176): getSurveyUserGroupList()

171             . "<input style='width: 15em;' type='submit' value='".$clang->gT("Add User")."'  onclick=\"if (document.getElementById('uidselect').value == -1) { alert('".$clang->gT("Please select a user first","js")."'); return false;}\"/>"
172             . "<input type='hidden' name='action' value='addsurveysecurity' />"
173             . "</li></ul></form>\n"
174             . "<form class='form44' action='".$this->getController()->createUrl('admin/surveypermission/addusergroup/surveyid/'.$surveyid)."' method='post'><ul><li>\n"
175             . "<label for='ugidselect'>".$clang->gT("Groups").": </label><select id='ugidselect' name='ugid'>\n"
176             . getSurveyUserGroupList('htmloptions',$surveyid)
177             . "</select>\n"
178             . "<input style='width: 15em;' type='submit' value='".$clang->gT("Add user group")."' onclick=\"if (document.getElementById('ugidselect').value == -1) { alert('".$clang->gT("Please select a user group first","js")."'); return false;}\" />"
179             . "<input type='hidden' name='action' value='addusergroupsurveysecurity' />\n"
180             . "</li></ul></form>";
181 

#4 	
 unknown(0): surveypermission->index(null, "simplegidarray")
#5 	
�
 /var/www/html/survey/framework/web/actions/CAction.php(107): ReflectionMethod->invokeArgs("htmloptions", "428269")

102             else if($param->isDefaultValueAvailable())
103                 $ps[]=$param->getDefaultValue();
104             else
105                 return false;
106         }
107         $method->invokeArgs($object,$ps);
108         return true;
109     }
110 }

#6 	
�
 /var/www/html/survey/application/core/Survey_Common_Action.php(82): CAction->runWithParamsInternal("428269")

77             $oMethod = new ReflectionMethod($this, $sDefault);
78         }
79 
80         // We're all good to go, let's execute it
81         // runWithParamsInternal would automatically get the parameters of the method and populate them as required with the params
82         return parent::runWithParamsInternal($this, $oMethod, $params);
83     }
84 
85     /**
86     * Some functions have different parameters, which are just an alias of the
87     * usual parameters we're getting in the url. This function just populates

#7 	
�
 /var/www/html/survey/framework/web/CController.php(309): Survey_Common_Action->runWithParams(surveypermission, array("428269"))

304     {
305         $priorAction=$this->_action;
306         $this->_action=$action;
307         if($this->beforeAction($action))
308         {
309             if($action->runWithParams($this->getActionParams())===false)
310                 $this->invalidActionParams($action);
311             else
312                 $this->afterAction($action);
313         }
314         $this->_action=$priorAction;

#8 	
�
 /var/www/html/survey/framework/web/CController.php(287): CController->runAction(surveypermission, ReflectionMethod, array("surveyid" => "428269", "sa" => "view", "iSurveyId" => "428269", "iSurveyID" => "428269"))

282      * @see runAction
283      */
284     public function runActionWithFilters($action,$filters)
285     {
286         if(empty($filters))
287             $this->runAction($action);
288         else
289         {
290             $priorAction=$this->_action;
291             $this->_action=$action;
292             CFilterChain::create($this,$action,$filters)->run();

#9 	
�
 /var/www/html/survey/framework/web/CController.php(266): CController->runActionWithFilters(array("surveyid" => "428269", "sa" => "view"))

261         {
262             if(($parent=$this->getModule())===null)
263                 $parent=Yii::app();
264             if($parent->beforeControllerAction($this,$action))
265             {
266                 $this->runActionWithFilters($action,$this->filters());
267                 $parent->afterControllerAction($this,$action);
268             }
269         }
270         else
271             $this->missingAction($actionID);

#10 	
�
 /var/www/html/survey/application/controllers/AdminController.php(159): CController->run(surveypermission)

154                 Yii::app()->session['redirectopage'] = Yii::app()->request->requestUri;
155 
156                 $this->redirect($this->createUrl('/admin/authentication/login'));
157             }
158 
159             return parent::run($action);
160     }
161 
162     /**
163     * Routes all the actions to their respective places
164     *

#11 	
�
 /var/www/html/survey/framework/web/CWebApplication.php(276): AdminController->run(surveypermission, array())

271         {
272             list($controller,$actionID)=$ca;
273             $oldController=$this->_controller;
274             $this->_controller=$controller;
275             $controller->init();
276             $controller->run($actionID);
277             $this->_controller=$oldController;
278         }
279         else
280             throw new CHttpException(404,Yii::t('yii','Unable to resolve the request "{route}".',
281                 array('{route}'=>$route===''?$this->defaultController:$route)));

#12 	
�
 /var/www/html/survey/framework/web/CWebApplication.php(135): CWebApplication->runController("surveypermission")

130             foreach(array_splice($this->catchAllRequest,1) as $name=>$value)
131                 $_GET[$name]=$value;
132         }
133         else
134             $route=$this->getUrlManager()->parseUrl($this->getRequest());
135         $this->runController($route);
136     }
137 
138     /**
139      * Registers the core application components.
140      * This method overrides the parent implementation by registering additional core components.

#13 	
�
 /var/www/html/survey/framework/base/CApplication.php(162): CWebApplication->processRequest("surveypermission")

157      */
158     public function run()
159     {
160         if($this->hasEventHandler('onBeginRequest'))
161             $this->onBeginRequest(new CEvent($this));
162         $this->processRequest();
163         if($this->hasEventHandler('onEndRequest'))
164             $this->onEndRequest(new CEvent($this));
165     }
166 
167     /**

#14 	
�
 /var/www/html/survey/index.php(178): CApplication->run("admin/surveypermission/sa/view")

173  *
174  */
175 require_once BASEPATH . 'yii' . EXT;
176 require_once APPPATH . 'core/LSYii_Application' . EXT;
177 
178 Yii::createApplication('LSYii_Application', APPPATH . 'config/config' . EXT)->run();
179 
180 /* End of file index.php */
181 /* Location: ./index.php */

2012-11-14 12:17:12 Apache Yii Framework/1.1.10
debug2_after_changeset.txt (10,779 bytes)   
debug2_after_changeset2.txt (8,493 bytes)   
CDbException

The table "{{survey_permissions}}" for active record class "Survey_permissions" cannot be found in the database.

/var/www/html/survey/framework/db/ar/CActiveRecord.php(2264)

2252     private $_model;
2253 
2254     /**
2255      * Constructor.
2256      * @param CActiveRecord $model the model instance
2257      */
2258     public function __construct($model)
2259     {
2260         $this->_model=$model;
2261 
2262         $tableName=$model->tableName();
2263         if(($table=$model->getDbConnection()->getSchema()->getTable($tableName))===null)
2264             throw new CDbException(Yii::t('yii','The table "{table}" for active record class "{class}" cannot be found in the database.',
2265                 array('{class}'=>get_class($model),'{table}'=>$tableName)));
2266         if($table->primaryKey===null)
2267         {
2268             $table->primaryKey=$model->primaryKey();
2269             if(is_string($table->primaryKey) && isset($table->columns[$table->primaryKey]))
2270                 $table->columns[$table->primaryKey]->isPrimaryKey=true;
2271             else if(is_array($table->primaryKey))
2272             {
2273                 foreach($table->primaryKey as $name)
2274                 {
2275                     if(isset($table->columns[$name]))
2276                         $table->columns[$name]->isPrimaryKey=true;

Stack Trace
#0 	
�
 /var/www/html/survey/framework/db/ar/CActiveRecord.php(379): CActiveRecordMetaData->__construct(Survey_permissions)

374         if(isset(self::$_models[$className]))
375             return self::$_models[$className];
376         else
377         {
378             $model=self::$_models[$className]=new $className(null);
379             $model->_md=new CActiveRecordMetaData($model);
380             $model->attachBehaviors($model->behaviors());
381             return $model;
382         }
383     }
384 

#1 	
�
 /var/www/html/survey/application/models/Survey_permissions.php(50): CActiveRecord::model("Survey_permissions")

45      * @param string $class
46      * @return CActiveRecord
47      */
48     public static function model($class = __CLASS__)
49     {
50         return parent::model($class);
51     }
52 
53     /**
54      * Returns the base permissions
55      *

#2 	
�
 /var/www/html/survey/application/controllers/admin/surveypermission.php(408): Survey_permissions::model()

403                 . "<th class='extended'>".$clang->gT("Import")."</th>\n"
404                 . "<th class='extended'>".$clang->gT("Export")."</th>\n"
405                 . "</tr></thead>\n";
406 
407                 //content
408                 $aBasePermissions=Survey_permissions::model()->getBasePermissions();
409 
410                 $oddcolumn=false;
411                 foreach($aBasePermissions as $sPermissionKey=>$aCRUDPermissions)
412                 {
413                     $oddcolumn=!$oddcolumn;

#3 	
 unknown(0): surveypermission->set("428269")
#4 	
�
 /var/www/html/survey/framework/web/actions/CAction.php(107): ReflectionMethod->invokeArgs(surveypermission, array("428269"))

102             else if($param->isDefaultValueAvailable())
103                 $ps[]=$param->getDefaultValue();
104             else
105                 return false;
106         }
107         $method->invokeArgs($object,$ps);
108         return true;
109     }
110 }

#5 	
�
 /var/www/html/survey/application/core/Survey_Common_Action.php(82): CAction->runWithParamsInternal(surveypermission, ReflectionMethod, array("surveyid" => "428269", "sa" => "set", "iSurveyId" => "428269", "iSurveyID" => "428269"))

77             $oMethod = new ReflectionMethod($this, $sDefault);
78         }
79 
80         // We're all good to go, let's execute it
81         // runWithParamsInternal would automatically get the parameters of the method and populate them as required with the params
82         return parent::runWithParamsInternal($this, $oMethod, $params);
83     }
84 
85     /**
86     * Some functions have different parameters, which are just an alias of the
87     * usual parameters we're getting in the url. This function just populates

#6 	
�
 /var/www/html/survey/framework/web/CController.php(309): Survey_Common_Action->runWithParams(array("surveyid" => "428269", "sa" => "set"))

304     {
305         $priorAction=$this->_action;
306         $this->_action=$action;
307         if($this->beforeAction($action))
308         {
309             if($action->runWithParams($this->getActionParams())===false)
310                 $this->invalidActionParams($action);
311             else
312                 $this->afterAction($action);
313         }
314         $this->_action=$priorAction;

#7 	
�
 /var/www/html/survey/framework/web/CController.php(287): CController->runAction(surveypermission)

282      * @see runAction
283      */
284     public function runActionWithFilters($action,$filters)
285     {
286         if(empty($filters))
287             $this->runAction($action);
288         else
289         {
290             $priorAction=$this->_action;
291             $this->_action=$action;
292             CFilterChain::create($this,$action,$filters)->run();

#8 	
�
 /var/www/html/survey/framework/web/CController.php(266): CController->runActionWithFilters(surveypermission, array())

261         {
262             if(($parent=$this->getModule())===null)
263                 $parent=Yii::app();
264             if($parent->beforeControllerAction($this,$action))
265             {
266                 $this->runActionWithFilters($action,$this->filters());
267                 $parent->afterControllerAction($this,$action);
268             }
269         }
270         else
271             $this->missingAction($actionID);

#9 	
�
 /var/www/html/survey/application/controllers/AdminController.php(159): CController->run("surveypermission")

154                 Yii::app()->session['redirectopage'] = Yii::app()->request->requestUri;
155 
156                 $this->redirect($this->createUrl('/admin/authentication/login'));
157             }
158 
159             return parent::run($action);
160     }
161 
162     /**
163     * Routes all the actions to their respective places
164     *

#10 	
�
 /var/www/html/survey/framework/web/CWebApplication.php(276): AdminController->run("surveypermission")

271         {
272             list($controller,$actionID)=$ca;
273             $oldController=$this->_controller;
274             $this->_controller=$controller;
275             $controller->init();
276             $controller->run($actionID);
277             $this->_controller=$oldController;
278         }
279         else
280             throw new CHttpException(404,Yii::t('yii','Unable to resolve the request "{route}".',
281                 array('{route}'=>$route===''?$this->defaultController:$route)));

#11 	
�
 /var/www/html/survey/framework/web/CWebApplication.php(135): CWebApplication->runController("admin/surveypermission/sa/set")

130             foreach(array_splice($this->catchAllRequest,1) as $name=>$value)
131                 $_GET[$name]=$value;
132         }
133         else
134             $route=$this->getUrlManager()->parseUrl($this->getRequest());
135         $this->runController($route);
136     }
137 
138     /**
139      * Registers the core application components.
140      * This method overrides the parent implementation by registering additional core components.

#12 	
�
 /var/www/html/survey/framework/base/CApplication.php(162): CWebApplication->processRequest()

157      */
158     public function run()
159     {
160         if($this->hasEventHandler('onBeginRequest'))
161             $this->onBeginRequest(new CEvent($this));
162         $this->processRequest();
163         if($this->hasEventHandler('onEndRequest'))
164             $this->onEndRequest(new CEvent($this));
165     }
166 
167     /**

#13 	
�
 /var/www/html/survey/index.php(178): CApplication->run()

173  *
174  */
175 require_once BASEPATH . 'yii' . EXT;
176 require_once APPPATH . 'core/LSYii_Application' . EXT;
177 
178 Yii::createApplication('LSYii_Application', APPPATH . 'config/config' . EXT)->run();
179 
180 /* End of file index.php */
181 /* Location: ./index.php */

2012-11-14 16:32:24 Apache Yii Framework/1.1.10
debug2_after_changeset2.txt (8,493 bytes)   
dump_limesurvey.sql (36,000 bytes)
Bug heat4
Complete LimeSurvey version number (& build)121113
I will donate to the project if issue is resolvedYes
Browserbrowser-independent
Database type & versionMySQL 4.1.21
Server OS (if known)Linux RedHat
Webserver software & version (if known)Apache
PHP VersionPHP Version 5.2.0

Users monitoring this issue

There are no users monitoring this issue.

Activities

c_schmitz

c_schmitz

2012-11-14 11:13

administrator   ~22138

Set debug to 2 in /application/config/config.php and let me know the detailed error on the 2nd issue.

rolandr

rolandr

2012-11-14 11:37

reporter   ~22140

please see debug2.txt for exception information

c_schmitz

c_schmitz

2012-11-14 11:51

administrator   ~22141

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&amp;id=10285

c_schmitz

c_schmitz

2012-11-14 11:52

administrator   ~22142

Thank you very much. That helped alot. This issue seem only to happen on a very minor number of system (I am not able to reproduce it here). However based on the error message I created a patch (see the changeset below)
Please let me know if it works.

rolandr

rolandr

2012-11-14 12:20

reporter   ~22143

thank you. unfortunately the 2 patches don't resolve the error on both issues. i added a debug information.

c_schmitz

c_schmitz

2012-11-14 12:25

administrator   ~22144

rolandr: well the issue is resolved, but it seems there are more.
You attached only one debug trace, can you please attach an updated one for the other issue, too?

c_schmitz

c_schmitz

2012-11-14 14:34

administrator   ~22147

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&amp;id=10287

rolandr

rolandr

2012-11-14 16:44

reporter   ~22160

thank you for the patch. we are getting closer. now i can add a user or group. but when i try to edit the rights i result in an error again. debug info can be found under "debug2_after_changeset2.txt".

i tried to generate a ebug trace for the global user rights problem, but it only tells me the known error - "Error executing query in dbSelectLimitAssoc:SELECT uid FROM lime_users WHERE parent_id=0" Setze Benutzerrechte:ulrike. is there any way i can generate a meaningful debug info for you?

c_schmitz

c_schmitz

2012-11-14 19:58

administrator   ~22161

Your installation seems to be missing a table 'survey_permissions' for whatever reasons. You will need to create it manually with an according prefix:

run this statement on your database (assuming that your table prefix is lime_):

CREATE TABLE IF NOT EXISTS lime_survey_permissions (
sid int(11) NOT NULL,
uid int(11) NOT NULL,
permission varchar(20) COLLATE utf8_unicode_ci NOT NULL,
create_p int(11) NOT NULL DEFAULT '0',
read_p int(11) NOT NULL DEFAULT '0',
update_p int(11) NOT NULL DEFAULT '0',
delete_p int(11) NOT NULL DEFAULT '0',
import_p int(11) NOT NULL DEFAULT '0',
export_p int(11) NOT NULL DEFAULT '0',
PRIMARY KEY (sid,uid,permission)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

then try again.

rolandr

rolandr

2012-11-14 20:08

reporter   ~22162

i checked and found out that the table is not missing. i installed the survey in a seperate database only for the survey but i didn't delete the prefix "lime_" during db-installation. i thought the installation routine examines if db is empty there is no use of the prefix. i hope this info helps.
i also attached a sql dump "dump_limesurvey.sql".

c_schmitz

c_schmitz

2012-11-14 20:18

administrator   ~22163

I am sorry but that is what the error message says:

The table "{{survey_permissions}}" for active record class "Survey_permissions" cannot be found in the database.

so however you have configured your prefix and database the related table is definitely missing.

rolandr

rolandr

2012-11-14 21:48

reporter   ~22164

i created the table as you mentioned above. the resulting error is the same.

as you i was wondering due to the fact that i checked the db via phpadmin relating to the error message given and realised that the "missing" table is there.

sorry for bringing you a headache about this!

c_schmitz

c_schmitz

2012-11-14 21:57

administrator   ~22165

As said, if the error message says the table is missing then it is still missing.
So either the error message has changed or the table is really missing - can't be both.

rolandr

rolandr

2012-11-14 22:09

reporter   ~22166

i know it sounds weired. but it is fact.
should i give you access to the phpadmin and limesurvey admin so you can check for yourself?

rolandr

rolandr

2012-11-14 22:23

reporter   ~22167

fact is also that when i'm adding a user to the survey rights the table "lime_survey_permissions" is accessed and data is written to it. when clicking on the pencil-icon to modify the rights of a user it tells us the table cannot be found.

c_schmitz

c_schmitz

2012-11-14 22:38

administrator   ~22168

Please send access data for LimeSurvey, phpMyAdmin and FTP to carsten.schmitz@limesurvey.org
All this will be treated confidential, of course. That way I will be able to debug directly instead of guessing what might be problem.

c_schmitz

c_schmitz

2012-11-15 09:20

administrator   ~22176

rolandr?

rolandr

rolandr

2012-11-15 09:57

reporter   ~22177

info is on it's way to you

rolandr

rolandr

2012-11-15 10:34

reporter   ~22178

ftp data is sent to you

c_schmitz

c_schmitz

2012-11-15 14:45

administrator   ~22182

Ok, thank you for the debug access - the issue is resolved now.
We are looking forward to your donation.

c_schmitz

c_schmitz

2012-11-15 14:46

administrator   ~22183

Fix committed to master branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&amp;id=10296

rolandr

rolandr

2012-11-15 16:36

reporter   ~22190

carsten, well done. thank you very much indeed! donation is on it's way.

c_schmitz

c_schmitz

2012-11-15 20:41

administrator   ~22205

Fix committed to 2.1 branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&amp;id=10309

c_schmitz

c_schmitz

2012-11-15 20:48

administrator   ~22208

Fix committed to 2.1 branch: http://bugs.limesurvey.org/plugin.php?page=Source/view&amp;id=10311

c_schmitz

c_schmitz

2012-11-16 10:40

administrator   ~22245

New version 2.00+ Build 121116 released

Related Changesets

LimeSurvey: master 0d327a50

2012-11-14 10:17:10

c_schmitz

Details Diff
Fixed issue 06867: Modification of user and survey rights results in an error Affected Issues
06867
mod - application/controllers/admin/usergroups.php Diff File
mod - application/helpers/common_helper.php Diff File

LimeSurvey: master 1e81f440

2012-11-14 11:36:35

c_schmitz

Details Diff
Fixed issue 06867: Modification of user and survey rights results in an error Affected Issues
06867
mod - application/helpers/common_helper.php Diff File

LimeSurvey: master 020ae9ec

2012-11-15 13:44:30

c_schmitz

Details Diff
Fixed issue 06867: Modification of user and survey rights results in an error Affected Issues
06867
mod - application/controllers/admin/surveypermission.php Diff File
mod - application/views/admin/user/setuserrights.php Diff File

LimeSurvey: 2.1 61f311d2

2012-11-15 19:40:52

c_schmitz

Details Diff
Fixed issue 06867: Modification of user and survey rights results in an error
Fixed issue 06869: Status icon broken / not shown on list of active survey with start date set
Affected Issues
06867, 06869
mod - application/controllers/admin/surveyadmin.php Diff File
mod - application/controllers/admin/usergroups.php Diff File
mod - application/helpers/common_helper.php Diff File

LimeSurvey: 2.1 07d8e30d

2012-11-15 19:46:56

c_schmitz

Details Diff
Fixed issue 06867: Modification of user and survey rights results in an error Affected Issues
06867
mod - application/controllers/admin/surveypermission.php Diff File
mod - application/views/admin/user/setuserrights.php Diff File

Issue History

Date Modified Username Field Change
2012-11-14 09:54 rolandr New Issue
2012-11-14 09:54 rolandr File Added: phpinfo.pdf
2012-11-14 11:13 c_schmitz Note Added: 22138
2012-11-14 11:13 c_schmitz Assigned To => c_schmitz
2012-11-14 11:13 c_schmitz Status new => feedback
2012-11-14 11:36 rolandr File Added: debug2.txt
2012-11-14 11:37 rolandr Note Added: 22140
2012-11-14 11:37 rolandr Status feedback => assigned
2012-11-14 11:51 c_schmitz Changeset attached => LimeSurvey master 0d327a50
2012-11-14 11:51 c_schmitz Note Added: 22141
2012-11-14 11:51 c_schmitz Resolution open => fixed
2012-11-14 11:52 c_schmitz Note Added: 22142
2012-11-14 11:52 c_schmitz Status assigned => feedback
2012-11-14 12:19 rolandr File Added: debug2_after_changeset.txt
2012-11-14 12:20 rolandr Note Added: 22143
2012-11-14 12:20 rolandr Status feedback => assigned
2012-11-14 12:25 c_schmitz Note Added: 22144
2012-11-14 13:16 c_schmitz Status assigned => feedback
2012-11-14 14:34 c_schmitz Changeset attached => LimeSurvey master 1e81f440
2012-11-14 14:34 c_schmitz Note Added: 22147
2012-11-14 16:38 rolandr File Added: debug2_after_changeset2.txt
2012-11-14 16:44 rolandr Note Added: 22160
2012-11-14 16:44 rolandr Status feedback => assigned
2012-11-14 19:58 c_schmitz Note Added: 22161
2012-11-14 20:08 rolandr Note Added: 22162
2012-11-14 20:09 rolandr File Added: dump_limesurvey.sql
2012-11-14 20:18 c_schmitz Note Added: 22163
2012-11-14 21:48 rolandr Note Added: 22164
2012-11-14 21:57 c_schmitz Note Added: 22165
2012-11-14 22:09 rolandr Note Added: 22166
2012-11-14 22:23 rolandr Note Added: 22167
2012-11-14 22:38 c_schmitz Note Added: 22168
2012-11-15 09:20 c_schmitz Note View State: 22168: public
2012-11-15 09:20 c_schmitz Note Added: 22176
2012-11-15 09:57 rolandr Note Added: 22177
2012-11-15 10:34 rolandr Note Added: 22178
2012-11-15 14:45 c_schmitz Note Added: 22182
2012-11-15 14:45 c_schmitz Status assigned => resolved
2012-11-15 14:45 c_schmitz Fixed in Version => 2.00+
2012-11-15 14:46 c_schmitz Changeset attached => LimeSurvey master 020ae9ec
2012-11-15 14:46 c_schmitz Note Added: 22183
2012-11-15 16:36 rolandr Note Added: 22190
2012-11-15 20:41 c_schmitz Changeset attached => LimeSurvey 2.1 61f311d2
2012-11-15 20:41 c_schmitz Note Added: 22205
2012-11-15 20:48 c_schmitz Changeset attached => LimeSurvey 2.1 07d8e30d
2012-11-15 20:48 c_schmitz Note Added: 22208
2012-11-16 10:40 c_schmitz Note Added: 22245
2012-11-16 10:40 c_schmitz Status resolved => closed