我目前正在执行以下操作:
$mysqli = new mysqli($server, $username, $password, $database);
$mysqli->multi_query($multiUpdates);
while ($mysqli->next_result()) {;} // Flushing results of multi_queries
$mysqli->query($sqlInserts);
有没有更快的方法来转储结果?
我不需要它们,只想运行下一个查询,但是出现错误:
命令不同步;你现在不能运行这个命令
问题是while ($mysqli->next_result()) {;}
大约需要 2 秒,这对于我不想要的东西来说是一种浪费。
有没有更好的解决方案?