]> git.joonet.de Git - adminer.git/commitdiff
SQLite: Fix non-PDO driver after 99163fe
authorJakub Vrana <jakub@vrana.cz>
Wed, 26 Mar 2025 10:39:06 +0000 (11:39 +0100)
committerJakub Vrana <jakub@vrana.cz>
Wed, 26 Mar 2025 10:39:06 +0000 (11:39 +0100)
adminer/drivers/sqlite.inc.php

index 98df1641c557bbd4842318b1c877344a69052601..76a3d47d47154dbf58ca07e880f5e8765c3e72f2 100644 (file)
@@ -8,8 +8,8 @@ if (isset($_GET["sqlite"])) {
        if (class_exists("SQLite3") && $_GET["ext"] != "pdo") {
 
                class SqliteDb {
-                       public $extension = "SQLite3", $server_info, $affected_rows, $errno, $error;
-                       private $link;
+                       public $extension = "SQLite3", $flavor = '', $server_info, $affected_rows, $errno, $error;
+                       private $link, $result;
 
                        function __construct($filename) {
                                $this->link = new \SQLite3($filename);
@@ -38,10 +38,19 @@ if (isset($_GET["sqlite"])) {
                                );
                        }
 
+
+                       function multi_query($query) {
+                               return $this->result = $this->query($query);
+                       }
+
                        function store_result() {
                                return $this->result;
                        }
 
+                       function next_result() {
+                               return false;
+                       }
+
                        function result($query, $field = 0) {
                                $result = $this->query($query);
                                if (!is_object($result)) {
@@ -100,8 +109,6 @@ if (isset($_GET["sqlite"])) {
 
        if (class_exists('Adminer\SqliteDb')) {
                class Db extends SqliteDb {
-                       public $flavor = '';
-
                        function __construct() {
                                parent::__construct(":memory:");
                                $this->query("PRAGMA foreign_keys = 1");