title: Prestashop Link to database cannot be established: SQLSTATE[HY000] [1226]
body: <p>I get an ERROR 500 when trying to access the BackOffice of my prestahsop, I can only enter with Debug mode on.</p>
  
  <p>My hosting provider told me I should close connections on the script, but I don't know what to insert or modify to which script.</p>
  
  <p>[PrestaShopException]
  Link to database cannot be established: SQLSTATE[HY000] [1226] User 'u488328531_pcFsK' has exceeded the 'max_user_connections' resource (current value: 15)
  at line 127 in file classes/db/DbPDO.php</p>
  
  <pre><code>122.     public function connect()
  123.     {
  124.         try {
  125.             $this-&gt;link = $this-&gt;getPDO($this-&gt;server, $this-&gt;user, $this-&gt;password, $this-&gt;database, 5);
  126.         } catch (PDOException $e) {
  127.             throw new PrestaShopException('Link to database cannot be established: ' . $e-&gt;getMessage());
  128.         }
  129. 
  130.         $this-&gt;link-&gt;exec('SET SESSION sql_mode = \'\'');
  131. 
  132.         return $this-&gt;link;
  
  
  DbPDOCore-&gt;connect - [line 330 - classes/db/Db.php]
  DbCore-&gt;__construct - [line 241 - classes/db/Db.php] - [4 Arguments]
  DbCore::getInstance - [line 47 - config/alias.php]
  pSQL - [line 340 - classes/shop/Shop.php] - [1 Arguments]
  ShopCore::initialize - [line 119 - config/config.inc.php]
  require - [line 40 - admin/index.php] - [1 Arguments]enter code here
  </code></pre>