]> git.joonet.de Git - adminer.git/commitdiff
Rename function with the same name as Driver::select
authorJakub Vrana <jakub@vrana.cz>
Fri, 28 Mar 2025 11:08:24 +0000 (12:08 +0100)
committerJakub Vrana <jakub@vrana.cz>
Fri, 28 Mar 2025 11:47:09 +0000 (12:47 +0100)
adminer/call.inc.php
adminer/drivers/mysql.inc.php
adminer/include/editing.inc.php
adminer/sql.inc.php

index be3a757137c163e3f8b7f0d38f67f73e8e2d98e2..36c9e333461b04b7a1b887afd53005800ea15c0e 100644 (file)
@@ -49,7 +49,7 @@ if (!$error && $_POST) {
                do {
                        $result = $connection->store_result();
                        if (is_object($result)) {
-                               select($result, $connection2);
+                               print_select_result($result, $connection2);
                        } else {
                                echo "<p class='message'>" . lang('Routine has been called, %d row(s) affected.', $affected)
                                        . " <span class='time'>" . @date("H:i:s") . "</span>\n" // @ - time zone may be not set
@@ -58,7 +58,7 @@ if (!$error && $_POST) {
                } while ($connection->next_result());
 
                if ($out) {
-                       select($connection->query("SELECT " . implode(", ", $out)));
+                       print_select_result($connection->query("SELECT " . implode(", ", $out)));
                }
        }
 }
index a55bab44163ec3fb6c51aeec470184059589419a..b0c8ca5a34bb525c895c193f0d5932e5d567a21f 100644 (file)
@@ -315,7 +315,7 @@ if (!defined('Adminer\DRIVER')) {
                        $result = $this->conn->query("SHOW WARNINGS");
                        if ($result && $result->num_rows) {
                                ob_start();
-                               select($result); // select() usually needs to print a big table progressively
+                               print_select_result($result); // print_select_result() usually needs to print a big table progressively
                                return ob_get_clean();
                        }
                }
index 59338d2b4e098e3559f43373185380b145c84165..626174c7e518a36be9f2a67c590feb4c96658c26 100644 (file)
@@ -10,7 +10,7 @@ namespace Adminer;
 * @param int|numeric-string $limit
 * @return string[] $orgtables
 */
-function select($result, Db $connection2 = null, array $orgtables = array(), $limit = 0): array {
+function print_select_result($result, Db $connection2 = null, array $orgtables = array(), $limit = 0): array {
        $links = array(); // colno => orgtable - create links from these columns
        $indexes = array(); // orgtable => array(column => colno) - primary keys
        $columns = array(); // orgtable => array(column => ) - not selected columns in primary key
index fe034a32636056a48ae4ed19cf1ee3501ba798f1..25dd0ce4039c3a8f3244b9459ab235726f4cccbd 100644 (file)
@@ -156,7 +156,7 @@ if (!$error && $_POST) {
                                                                        $explain_id = "explain-$commands";
                                                                        if (is_object($result)) {
                                                                                $limit = $_POST["limit"];
-                                                                               $orgtables = select($result, $connection2, array(), $limit);
+                                                                               $orgtables = print_select_result($result, $connection2, array(), $limit);
                                                                                if (!$_POST["only_errors"]) {
                                                                                        echo "<form action='' method='post'>\n";
                                                                                        $num_rows = $result->num_rows;
@@ -188,7 +188,7 @@ if (!$error && $_POST) {
                                                                        echo ($warnings ? "<div id='$warnings_id' class='hidden'>\n$warnings</div>\n" : "");
                                                                        if ($explain) {
                                                                                echo "<div id='$explain_id' class='hidden explain'>\n";
-                                                                               select($explain, $connection2, $orgtables);
+                                                                               print_select_result($explain, $connection2, $orgtables);
                                                                                echo "</div>\n";
                                                                        }
                                                                }