sql >> Database teknologi >  >> Database Tools >> SQLyog

At indstille MySQL-forbindelse/server til utf8mb4 i stedet for uft8 bryder lagrede procedurer i SQLYog

Fra SQLyog:

SET NAMES 'utf8mb4' COLLATE 'utf8_bin';

Error Code: 1253
COLLATION 'utf8_bin' is not valid for CHARACTER SET 'utf8mb4'

prøv:

SET NAMES 'utf8mb4' COLLATE 'utf8mb4_bin';

Brug af SQLyog Community v12.2.2 (64 bit) og MySQL 5.5.49 kan ændre (åbne) og skabe nye lagrede procedurer uden problemer.

VERSION()
-----------
5.5.49

SET NAMES 'utf8mb4' COLLATE  'utf8mb4_bin';

SET SESSION collation_connection = 'utf8mb4_bin',
            collation_server = 'utf8mb4_bin',
            collation_database = 'utf8mb4_bin';

SHOW VARIABLES WHERE
    `Variable_Name` != 'character_sets_dir' AND
    (`Variable_Name` LIKE '%CHAR%' OR
    `Variable_Name` LIKE '%COLL%');

Variable_name             Value        
------------------------  -------------
character_set_client      utf8mb4      
character_set_connection  utf8mb4      
character_set_database    utf8mb4      
character_set_filesystem  binary       
character_set_results     utf8mb4      
character_set_server      utf8mb4      
character_set_system      utf8         
collation_connection      utf8mb4_bin  
collation_database        utf8mb4_bin  
collation_server          utf8mb4_bin



  1. Aktivering af file_get_contents på en delt server

  2. Sådan indstilles standardlagringsmotoren til InnoDB i XAMPP

  3. Sådan løses XAMPP 1.7.7 - PHPMyAdmin - MySQL-fejl #2002 i Ubuntu

  4. PhpMyAdmin opdaterer automatisk MySQL-tabel