]> git.joonet.de Git - adminer.git/commitdiff
Set application_name (thanks to juzna)
authorJakub Vrana <jakub@vrana.cz>
Tue, 23 Aug 2011 12:23:48 +0000 (14:23 +0200)
committerJakub Vrana <jakub@vrana.cz>
Tue, 23 Aug 2011 12:23:48 +0000 (14:23 +0200)
adminer/drivers/pgsql.inc.php

index 6eea08c3897e02a58ee9666290768f1cee310f0b..71057e5cb0cec93d629fff8a67382be091f88739 100644 (file)
@@ -161,6 +161,9 @@ if (isset($_GET["pgsql"])) {
                $connection = new Min_DB;
                $credentials = $adminer->credentials();
                if ($connection->connect($credentials[0], $credentials[1], $credentials[2])) {
+                       if ($connection->server_info >= 9) {
+                               $connection->query("SET application_name = 'Adminer'");
+                       }
                        return $connection;
                }
                return $connection->error;