TDbConnection failed to establish DB connection: SQLSTATE[HY000] [1040] Too many connections (Error Code: 0)
${PradoFramework}/Data/TDbConnection.php (206)
0195: );
0196: // This attribute is only useful for PDO::MySql driver.
0197: // Ignore the warning if a driver doesn't understand this.
0198: @$this->_pdo->setAttribute(PDO::ATTR_EMULATE_PREPARES, true);
0199: // This attribute is only useful for PDO::MySql driver since PHP 8.1
0200: // This ensures integers are returned as strings (needed eg. for ZEROFILL columns)
0201: @$this->_pdo->setAttribute(PDO::ATTR_STRINGIFY_FETCHES, true);
0202: $this->_pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
0203: $this->_active = true;
0204: $this->setConnectionCharset();
0205: } catch (PDOException $e) {
0206: throw new TDbException('dbconnection_open_failed', $e->getMessage());
0207: }
0208: }
0209: }
0210:
0211: /**
0212: * Closes the currently active DB connection.
0213: * It does nothing if the connection is already closed.
0214: */
0215: protected function close()
0216: {
0217: $this->_pdo = null;
0218: $this->_active = false;
#0 ${PradoFramework}/Data/TDbConnection.php(175): Prado\Data\TDbConnection->open()
#1 ${PradoFramework}/TComponent.php(898): Prado\Data\TDbConnection->setActive()
#2 ${DocumentRoot}/protected/pages/MyPage.php(313): Prado\TComponent->__set()
#3 ${DocumentRoot}/protected/pages/IndiceLuoghi.php(138): MyPage->findAllBySql()
#4 ${DocumentRoot}/protected/pages/IndiceLuoghi.php(78): IndiceLuoghi->getRiferimentiLuogo()
#5 ${PradoFramework}/TComponent.php(1508): IndiceLuoghi->repLuoghiScritture_OnItemDataBound()
#6 ${PradoFramework}/Web/UI/WebControls/TRepeater.php(731): Prado\TComponent->raiseEvent()
#7 ${PradoFramework}/Web/UI/WebControls/TRepeater.php(496): Prado\Web\UI\WebControls\TRepeater->onItemDataBound()
#8 ${PradoFramework}/Web/UI/WebControls/TRepeater.php(674): Prado\Web\UI\WebControls\TRepeater->createItemWithDataInternal()
#9 ${PradoFramework}/Web/UI/WebControls/TDataBoundControl.php(354): Prado\Web\UI\WebControls\TRepeater->performDataBinding()
#10 ${DocumentRoot}/protected/pages/IndiceLuoghi.php(47): Prado\Web\UI\WebControls\TDataBoundControl->dataBind()
#11 ${PradoFramework}/TComponent.php(1508): IndiceLuoghi->repLuoghi_OnItemDataBound()
#12 ${PradoFramework}/Web/UI/WebControls/TRepeater.php(731): Prado\TComponent->raiseEvent()
#13 ${PradoFramework}/Web/UI/WebControls/TRepeater.php(496): Prado\Web\UI\WebControls\TRepeater->onItemDataBound()
#14 ${PradoFramework}/Web/UI/WebControls/TRepeater.php(674): Prado\Web\UI\WebControls\TRepeater->createItemWithDataInternal()
#15 ${PradoFramework}/Web/UI/WebControls/TDataBoundControl.php(354): Prado\Web\UI\WebControls\TRepeater->performDataBinding()
#16 ${DocumentRoot}/protected/pages/IndiceLuoghi.php(29): Prado\Web\UI\WebControls\TDataBoundControl->dataBind()
#17 ${PradoFramework}/Web/UI/TControl.php(1359): IndiceLuoghi->onInit()
#18 ${PradoFramework}/Web/UI/TCompositeControl.php(32): Prado\Web\UI\TControl->initRecursive()
#19 ${PradoFramework}/Web/UI/TTemplateControl.php(251): Prado\Web\UI\TCompositeControl->initRecursive()
#20 ${PradoFramework}/Web/UI/TPage.php(233): Prado\Web\UI\TTemplateControl->initRecursive()
#21 ${PradoFramework}/Web/UI/TPage.php(221): Prado\Web\UI\TPage->processNormalRequest()
#22 ${PradoFramework}/Web/Services/TPageService.php(535): Prado\Web\UI\TPage->run()
#23 ${PradoFramework}/Web/Services/TPageService.php(453): Prado\Web\Services\TPageService->runPage()
#24 ${PradoFramework}/TApplication.php(1328): Prado\Web\Services\TPageService->run()
#25 ${PradoFramework}/TApplication.php(409): Prado\TApplication->runService()
#26 ${DocumentRoot}/index.php(23): Prado\TApplication->run()
#27 {main}