Selaa lähdekoodia

#1054 Convert all field from utf8 to utf8mb4

Alex Trofimov 8 vuotta sitten
vanhempi
sitoutus
f7c8588a40
1 muutettua tiedostoa jossa 2 lisäystä ja 2 poistoa
  1. 2 2
      upgrade/classes/BxDolUpgradeDb.php

+ 2 - 2
upgrade/classes/BxDolUpgradeDb.php

@@ -61,7 +61,7 @@ class BxDolUpgradeDb
 
         $this->_sStorageEngine = 'MYISAM';
 
-        $this->_sCharset = 'utf8';
+        $this->_sCharset = 'utf8mb4';
 
         $this->_sHost = BX_DATABASE_HOST;
         $this->_sPort = BX_DATABASE_PORT;
@@ -116,7 +116,7 @@ class BxDolUpgradeDb
 				PDO::ATTR_PERSISTENT => $this->_bPdoPersistent
 	        ));
 
-	    	$this->pdoExec("SET NAMES 'utf8'");
+	    	$this->pdoExec("SET NAMES 'utf8mb4' COLLATE 'utf8mb4_unicode_ci'");
 	        $this->pdoExec("SET sql_mode = ''");
 			$this->pdoExec("SET storage_engine=" . $this->_sStorageEngine);