mirror of
https://github.com/wavelog/wavelog.git
synced 2026-03-22 10:24:14 +00:00
make the install.sql import much faster
This commit is contained in:
@@ -40,12 +40,12 @@ class Database {
|
||||
// Execute a multi query
|
||||
$mysqli->multi_query($newquery);
|
||||
|
||||
// MultiQuery is NON-Blocking,so wait until everything is done
|
||||
// Drain all results to ensure the server finishes processing.
|
||||
do {
|
||||
null;
|
||||
} while ($mysqli->next_result());
|
||||
|
||||
$mysqli->store_result();
|
||||
if ($result = $mysqli->store_result()) {
|
||||
$result->free();
|
||||
}
|
||||
} while ($mysqli->more_results() && $mysqli->next_result());
|
||||
|
||||
// Close the connection
|
||||
$mysqli->close();
|
||||
|
||||
Reference in New Issue
Block a user