From: Jakub Vrana Date: Sun, 17 Apr 2011 02:36:48 +0000 (+0200) Subject: Fix 'Commands out of sync' (thanks to Vlasta Neubauer) X-Git-Tag: v3.3.0~95 X-Git-Url: https://git.joonet.de/?a=commitdiff_plain;h=417b29fe657e614b3dd830681c2e41c4d32e4636;p=adminer.git Fix 'Commands out of sync' (thanks to Vlasta Neubauer) --- diff --git a/adminer/call.inc.php b/adminer/call.inc.php index 0620b441..8feb3293 100644 --- a/adminer/call.inc.php +++ b/adminer/call.inc.php @@ -33,10 +33,14 @@ if (!$error && $_POST) { if (!$connection->multi_query($query)) { echo "

" . error() . "\n"; } else { + $connection2 = connect(); + if (is_object($connection2)) { + $connection2->select_db(DB); + } do { $result = $connection->store_result(); if (is_object($result)) { - select($result); + select($result, $connection2); } else { echo "

" . lang('Routine has been called, %d row(s) affected.', $connection->affected_rows) . "\n"; }