Fixed MySQL8 incompatibility
authorMarcel Werk <burntime@woltlab.com>
Mon, 28 Mar 2022 13:43:07 +0000 (15:43 +0200)
committerMarcel Werk <burntime@woltlab.com>
Mon, 28 Mar 2022 13:43:07 +0000 (15:43 +0200)
files/lib/system/exporter/IPB3xExporter.class.php

index ddf7d772c54b1e2789d052eccd52b74a14e2d2c4..b1c98216e677d78f0fde527cfbad46e790d11aa1 100644 (file)
@@ -383,7 +383,7 @@ class IPB3xExporter extends AbstractExporter
      */
     public function countUserGroups()
     {
-        return $this->__getMaxID($this->databasePrefix . "groups", 'g_id');
+        return $this->__getMaxID("`" . $this->databasePrefix . "groups`", 'g_id');
     }
 
     /**
@@ -395,7 +395,7 @@ class IPB3xExporter extends AbstractExporter
     public function exportUserGroups($offset, $limit)
     {
         $sql = "SELECT      *
-                FROM        " . $this->databasePrefix . "groups
+                FROM        `" . $this->databasePrefix . "groups`
                 WHERE       g_id BETWEEN ? AND ?
                 ORDER BY    g_id";
         $statement = $this->database->prepareStatement($sql);