diff --git a/core/lib/Drupal/Core/Database/Driver/mysql/Connection.php b/core/lib/Drupal/Core/Database/Driver/mysql/Connection.php
index f79b9f9144..3414c47390 100644
--- a/core/lib/Drupal/Core/Database/Driver/mysql/Connection.php
+++ b/core/lib/Drupal/Core/Database/Driver/mysql/Connection.php
@@ -90,6 +90,20 @@ class Connection extends DatabaseConnection {
    */
   protected $identifierQuotes = ['"', '"'];
 
+  /**
+   * {@inheritdoc}
+   */
+  public function __construct(\PDO $connection, array $connection_options) {
+    // If the SQL mode doesn't include 'ANSI_QUOTES' (explicitly or via the
+    // 'ANSI' combination mode), then MySQL doesn't interpret a double quote as
+    // an identifier quote, in which case use the non-ANSI-standard backtick.
+    // @see https://dev.mysql.com/doc/refman/8.0/en/sql-mode.html#sqlmode_ansi_quotes
+    if ($this->identifierQuotes === ['"', '"'] && !str_contains($connection_options['init_commands']['sql_mode'], 'ANSI')) {
+      $this->identifierQuotes = ['`', '`'];
+    }
+    parent::__construct($connection, $connection_options);
+  }
+
   /**
    * {@inheritdoc}
    */
diff --git a/core/tests/Drupal/KernelTests/Core/Database/SqlModeTest.php b/core/tests/Drupal/KernelTests/Core/Database/SqlModeTest.php
new file mode 100644
index 0000000000..1faff7cf64
--- /dev/null
+++ b/core/tests/Drupal/KernelTests/Core/Database/SqlModeTest.php
@@ -0,0 +1,31 @@
+<?php
+
+namespace Drupal\KernelTests\Core\Database;
+
+/**
+ * Tests compatibility of database drivers with various sql_mode options.
+ *
+ * @group Database
+ */
+class SqlModeTest extends DatabaseTestBase {
+
+  /**
+   * Tests quoting identifiers in queries.
+   */
+  public function testQuotingIdentifiers() {
+    // Use the table named an ANSI SQL reserved word with a column that is as
+    // well.
+    $result = $this->connection->query('SELECT [update] FROM {select}')->fetchObject();
+    $this->assertEquals('Update value 1', $result->update);
+  }
+
+  /**
+   * {@inheritdoc}
+   */
+  protected function getDatabaseConnectionInfo() {
+    $info = parent::getDatabaseConnectionInfo();
+    $info['default']['init_commands']['sql_mode'] = "SET sql_mode = ''";
+    return $info;
+  }
+
+}
