I have a script which loops over tables and fields doing a find and replace. The script takes around 4 minutes to complete. The database is about 1.5GB.
The problem is that I am somehow loosing the database connection. I am using ADODB to connect to mySQL. The db connection is opened at the beginning and remains open the whole duration of the script.
The problem disappears when I use the following code:
if ($rowCount % 100000 == 0) {
$db->Execute('USE ' . $db->database);
}
I am not a fan of this solution!
Any suggestions/explanations/discussions that help me to stop scratching my head would be greatly appreciated!
JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)