MySQL SQL -Status [HY000] [1203] Der Benutzer XXXXX hat bereits mehr als 'max_user_connections' aktive VerbindungenPhp

PHP-Programmierer chatten hier
Anonymous
 MySQL SQL -Status [HY000] [1203] Der Benutzer XXXXX hat bereits mehr als 'max_user_connections' aktive Verbindungen

Post by Anonymous »

Ich habe festgestellt, dass mein Rückgabewert von $ sth-> fetch (pdo :: fetch_assoc): < /p>

lautetSQLSTATE[HY000] [1203] User *USERNAMEHERE* already has more than 'max_user_connections' active connections< /code> < /p>

Alle meine Abfragen sind erfolgreich und alles scheint einwandfrei zu funktionieren. Hier ist meine Funktion, irgendwelche Ideen, warum ich maxiere? < /P>

function mysql_read_single_row($sql, $array_of_values) {

try {
//create a connection
$DBH = new PDO("mysql:host=".CONST_MYSQL_HOST.";dbname=".CONST_MYSQL_DBNAME, CONST_MYSQL_RUSER, CONST_MYSQL_RPASS);

//set the sql
$STH = $DBH->prepare($sql);

//execute query
$STH->execute($array_of_values);
}
catch(PDOException $e) {
echo $e->getMessage();
return false;
}

$return_row = $STH->fetch(PDO::FETCH_ASSOC);

//close the connection
$STH = null;
$DBH = null;

//strip any escaped quotes from the data
$return_row = array_map('stripslashes', $return_row);

//return the array
return $return_row;
}
< /code>

Setzt $ STH und $ DBH nicht ausreichend, um diesen Fehler zu verhindern? < /p>

Quick Reply

Change Text Case: 
   
  • Similar Topics
    Replies
    Views
    Last post