Tagged articles
character-set
57 articles · Page 1 of 1
This tutorial demonstrates MySQL 8.0 configuration of character sets, collations, time zones, and SQL modes through reproducible experiments, showing how connection settings differ from server defaults, how utf8mb4 handles emojis, why TIMESTAMP converts across time zones while DATETIME does not, and how strict SQL mode rejects out-of-range values.
MySQLcharacter-setcollation
0 likes · 20 min read

The article explains the difference between character sets and encodings, shows that MySQL’s utf8 is actually an alias for utf8mb3, demonstrates how using the wrong charset or collation causes garbled data, and provides practical steps to consistently use utf8mb4 across versions and connections.
MySQLcharacter-setcollation
0 likes · 13 min read

The article explains MySQL’s full range of data types—from integers and floating‑point numbers to strings, binary and temporal types—along with constraint options such as NOT NULL, UNIQUE, CHECK, primary keys and AUTO_INCREMENT, and offers practical guidelines on character sets, collations, and best‑practice selection to ensure data integrity, consistency, and optimal storage and query performance.
MySQLcharacter-setcollation
0 likes · 11 min read

MySQL’s original utf8 implementation was a limited, buggy version that only supported three‑byte characters, leading to data loss for emojis and rare symbols, so MySQL introduced utf8mb4 as a full UTF‑8 solution and now recommends it as the default encoding.
MySQLcharacter-setdatabases
0 likes · 5 min read

This article explains MySQL's supported character sets and collations, shows how to list them, demonstrates table‑level and column‑level definitions, clarifies naming conventions, and provides practical examples for verifying and altering collations to ensure correct string comparison and storage.
MySQLSQLcharacter-set
0 likes · 10 min read


ITPUBNov 3, 2025 · Databases
Although MySQL historically labeled its three‑byte character set as “utf8”, it actually implements a truncated version (utf8mb3) that cannot store the full Unicode range, leading to bugs with emojis and rare characters; the newer utf8mb4 restores true UTF‑8 support and is now the default in MySQL 8.0.
MySQLUnicodecharacter-set
0 likes · 7 min read

Learn how to diagnose and permanently fix MySQL character set problems—like garbled Chinese text or missing emoji—by checking current settings, altering databases and tables to utf8mb4, updating the my.cnf configuration, and avoiding common pitfalls, all with clear command examples.
MySQLSQLcharacter-set
0 likes · 5 min read

This tutorial walks through preparing the environment, installing and uninstalling MySQL on CentOS 7, configuring firewalls, setting up remote access, handling character sets, adjusting security policies, managing SQL modes, and best practices for case sensitivity and version‑specific password policies.
ConfigurationLinuxMySQL
0 likes · 30 min read

A collection of Zhihu answers explains that MySQL’s original utf8 charset only supports three‑byte characters, causing data loss for emojis and rare symbols, and shows how the newer utf8mb4 charset provides full Unicode support, becoming the default in MySQL 8.0.
MySQLcharacter-setutf8
0 likes · 7 min read

This article explains why upgrading MySQL from 5.7 to 8.0 can cause an "Illegal mix of collations" error in FIND_IN_SET queries, analyzes the root cause, and presents three practical solutions—adjusting server parameters, altering table collations, or rewriting the SQL—to restore correct operation.
MySQLSQLUpgrade
0 likes · 10 min read

This article explains why inserting emoji characters into a MySQL table defined with the default utf8 charset triggers a string‑value error, explores the underlying encoding and charset concepts, compares utf8mb3 and utf8mb4, and shows how to convert tables to avoid such failures.
MySQLcharacter-setcollation
0 likes · 9 min read

This article explains why MySQL’s built‑in utf8 charset only supports three‑byte characters, why emojis cause errors, and how switching to the proper utf8mb4 charset resolves insertion issues while preserving full Unicode support.
MySQLcharacter-setdatabase
0 likes · 9 min read

The article investigates why altering a MySQL VARCHAR column from a length that fits within 255 bytes to one that exceeds this limit (e.g., VARCHAR(63) to VARCHAR(64) in utf8mb4) triggers a costly copy operation, analyzes the storage mechanics, reproduces the issue, and provides practical recommendations to avoid performance penalties.
MySQLcharacter-setdatabase administration
0 likes · 13 min read

Discover why MySQL’s legacy ‘utf8’ charset only supports three‑byte characters, causing storage errors for true UTF‑8 data, and learn how the ‘utf8mb4’ charset resolves these issues, with historical context, technical details, and migration guidance.
MariaDBMySQLcharacter-set
0 likes · 7 min read

The article explains why MySQL’s built‑in utf8 charset cannot store four‑byte characters such as emojis, demonstrates the resulting insert error, shows how switching the database, table and connection to utf8mb4 fixes the issue, and recounts the historical reasons behind MySQL’s limited utf8 implementation.
MySQLcharacter-setemoji
0 likes · 8 min read

This article explores MySQL character set implementation by analyzing system tables (CHARACTER_SETS and COLLATIONS) in information_schema and tracing internal source code structures like CHARSET_INFO, initialization logic, and client connection handling.
Client-Server ProtocolDatabase InternalsMySQL
0 likes · 6 min read

This article explores how MySQL determines the maximum length of VARCHAR columns, showing that the limit depends on the chosen character set, nullability, and column count, and explains the underlying row storage format and how to handle oversized strings.
Dynamic StorageMaximum LengthMySQL
0 likes · 13 min read

This article analyzes why MySQL 8.0 reports an illegal mix of collations when querying a view that joins tables with different character sets, demonstrates reproducing the issue, explains the role of the CONVERT function and default collation variables, and provides practical recommendations to avoid such errors.
Convert FunctionMySQLcharacter-set
0 likes · 9 min read

This article explains why MySQL's default utf8 charset cannot store four‑byte characters such as emojis, demonstrates the resulting insertion error, and shows how switching to the utf8mb4 charset resolves the issue while also covering the historical reasons behind MySQL's limited utf8 implementation.
MySQLSQLcharacter-set
0 likes · 8 min read

This article walks through a real‑world MySQL slow‑query case, detailing analysis, index checks, character‑set alignment, forced index usage, and IN‑clause considerations that together reduced a 5‑second query to under one second.
IN ClauseIndex OptimizationMySQL
0 likes · 4 min read

This article explains MySQL collations and character sets, shows how to view and set them, and demonstrates through test cases that while data insertion is unaffected by collation, query results are influenced by the collation defined on columns or the connection.
MySQLcharacter-setcollation
0 likes · 6 min read

The article investigates why two MySQL 5.7.32 installations on RedHat 7 show different client character sets—utf8 in the first batch and latin1 in the second—by reviewing MySQL charset settings, OS locale configuration, and providing corrective commands.
Database ConfigurationLinuxMySQL
0 likes · 7 min read


政采云技术Dec 7, 2021 · Databases
This article examines how MySQL Connector/J determines the character set during connection initialization, explains the transition from UTF8MB3 to UTF8MB4, analyzes source code of versions 5.1.46 and 5.1.47, and provides practical methods to enable UTF8MB4 without upgrading the driver.
Connector/JJavaMySQL
0 likes · 10 min read

This article explains why inserting emoji into MySQL fails with the default utf8 charset, demonstrates how switching to utf8mb4 resolves the issue, and provides a historical overview of MySQL's limited utf8 implementation and the proper use of true UTF‑8 encoding.
MySQLUnicodecharacter-set
0 likes · 7 min read

This article explains the difference between MySQL’s utf8 and utf8mb4 character sets, why utf8 cannot store emojis or complex Chinese characters, and provides step‑by‑step examples showing how to configure tables and columns with utf8mb4 to avoid encoding errors.
MySQLcharacter-setemoji
0 likes · 10 min read

The article explains that MySQL’s legacy “utf8” charset only supports three‑byte characters, causing errors when storing true four‑byte UTF‑8 symbols, and shows how the newer “utf8mb4” charset provides full Unicode support, with historical context and migration guidance.
MariaDBMySQLcharacter-set
0 likes · 7 min read

This article explains MySQL's Unicode character set support, compares the deprecated utf8mb3 with the modern utf8mb4, and provides step‑by‑step SQL commands for safely converting existing databases to the newer charset.
Database MigrationMySQLUnicode
0 likes · 7 min read

This article explains why characters appear as garbled text when encoding and decoding methods mismatch, explores how Excel defaults to GBK, shows how to convert files with iconv, and walks through the evolution from ASCII to GB2312, GBK, GB18030, and finally Unicode's UTF‑8 encoding.
GBKUTF-8Unicode
0 likes · 6 min read

This article explains why a MySQL join query may ignore an index because of implicit character‑set conversion, demonstrates how to diagnose the issue with EXPLAIN and schema queries, and provides a fix by converting the column to UTF8 in the SQL statement.
IndexMySQLSQL
0 likes · 4 min read

This article explains why MySQL's legacy utf8 charset cannot store four‑byte characters such as emoji, demonstrates the resulting insertion error, and shows how switching the database, table, and column collations to utf8mb4 resolves the issue while also covering the historical reasons behind MySQL's limited utf8 implementation.
MySQLcharacter-setemoji
0 likes · 7 min read

The article explains how MySQL's Online DDL handles VARCHAR column expansions, demonstrates performance differences across character sets using sysbench, and clarifies why certain size changes trigger in‑place alterations while others require full table copies, providing practical guidance for DBAs.
InnoDBMySQLcharacter-set
0 likes · 9 min read

The article explains why MySQL’s built‑in utf8 charset only supports up to three‑byte characters, causing insert errors with four‑byte emojis, and shows how switching tables, system, and connection settings to utf8mb4 resolves the issue while detailing the historical reasons behind this limitation.
character-setdatabase encodingemoji
0 likes · 9 min read

The article explains that MySQL’s legacy "utf8" charset only supports three‑byte sequences, causing errors with true four‑byte Unicode characters, and shows how the later "utf8mb4" charset provides proper UTF‑8 support along with historical context and migration guidance.
MariaDBMySQLcharacter-set
0 likes · 8 min read

This article explains why MySQL data can become garbled due to mismatched character sets during insertion or retrieval, explores various scenarios such as client‑side encoding errors, mixed encodings within tables, and LATIN1 storage, and provides detailed solutions including setting proper client encodings, using strict SQL_MODE, and exporting/importing data to unify character sets.
MySQLSQLcharacter-set
0 likes · 15 min read

The article explains that MySQL’s legacy “utf8” character set only supports three‑byte sequences and therefore cannot store true UTF‑8 characters, describes the historical reasons behind this limitation, and advises all MySQL/MariaDB users to migrate to the proper utf8mb4 charset.
MariaDBMySQLcharacter-set
0 likes · 12 min read

This article explains the fundamentals of Oracle character sets, how database and national character sets are defined, the role of NLS_LANG, the location and purpose of character set files, and practical guidance for import/export operations and character set conversion across different environments.
Import ExportNLS_LANGOracle
0 likes · 22 min read

This article explains how to specify and manage character sets and collations when creating or altering MySQL databases, tables, views, triggers, and columns, illustrating the impact on stored procedures and data retrieval with practical SQL examples.
MySQLSQLTable
0 likes · 11 min read

This article explains MySQL character sets and collations, describes common character sets such as latin1, utf8mb3, utf8mb4 and gb18030, shows how to query available sets and collations, compares PAD SPACE and NO PAD behavior, and provides step‑by‑step migration examples between utf8, utf8mb3 and utf8mb4.
MySQLcharacter-setcollation
0 likes · 12 min read

This article explains how MySQL’s character_set parameters such as character_set_client and character_set_results control the encoding and decoding of client commands and query results, illustrates common pitfalls with UTF‑8, GBK and Latin‑1, and provides practical commands to avoid garbled text.
GBKMySQLUTF-8
0 likes · 10 min read


ITPUBFeb 28, 2020 · Databases
This article explains the root causes of MySQL character‑set garbling, illustrates the encoding/decoding steps during data insertion and retrieval, and provides practical methods—including dump‑reload and binary conversion—to prevent and repair corrupted data.
MySQLSQLcharacter-set
0 likes · 13 min read


ITPUBJan 7, 2020 · Databases
The article explains that MySQL’s legacy “utf8” charset only supports three‑byte characters, causing errors when storing true four‑byte UTF‑8 data, and shows how switching to the proper “utf8mb4” charset resolves the issue.
MariaDBMySQLcharacter-set
0 likes · 8 min read


ITPUBOct 10, 2019 · Databases
The article explains that MySQL’s legacy “utf8” charset only supports three‑byte characters, causing errors when storing true four‑byte UTF‑8 symbols like emojis, and shows why switching to the proper “utf8mb4” charset is essential for correct Unicode handling.
MariaDBMySQLUnicode
0 likes · 8 min read

This article explains MySQL's character set and collation variables, illustrates how they interact during data import, analyzes a failure caused by mismatched charset settings, and provides guidance on proper configuration and troubleshooting of encoding problems.
MySQLcharacter-setencoding
0 likes · 7 min read

This article explores MySQL’s advanced capabilities—including partition tables, views, stored procedures, triggers, foreign‑key constraints, bind variables, user‑defined functions, and character‑set considerations—explaining their principles, usage patterns, performance impacts, and best‑practice recommendations for handling large‑scale data.
Foreign KeysMySQLPartitioning
0 likes · 34 min read


ITPUBApr 9, 2018 · Databases
This article explains the root causes of MySQL character‑set garbling, details the encoding and decoding steps during data storage and retrieval, and provides practical methods—including dump/reload and binary conversion—to prevent and repair corrupted text.
MySQLcharacter-setcharset conversion
0 likes · 14 min read

This article explores MySQL’s advanced features—including partition tables, views, stored procedures, triggers, foreign key constraints, bind variables, user‑defined functions, and character set considerations—explaining their principles, usage patterns, performance implications, and practical tips for large‑scale data scenarios.
MySQLPartitioningUDF
0 likes · 35 min read


21CTOAug 30, 2017 · Databases
This article presents nine classic MySQL error cases—from connection limits and replication conflicts to installation permission issues, forgotten passwords, auto‑increment resets, character‑set garbling, binlog misconfiguration, timeout problems, and file‑open limits—each accompanied by clear diagnosis steps and practical solutions.
Database ErrorsMySQLReplication
0 likes · 16 min read


ITPUBJul 21, 2017 · Databases
This article explains why MySQL throws "Incorrect string value" when storing emojis, how utf8mb4 solves the problem, and provides step‑by‑step instructions—including table conversion, my.cnf changes, connector upgrades, and runtime workarounds—for reliable emoji storage.
JDBCMyBatisMySQL
0 likes · 7 min read


ITPUBJun 21, 2017 · Databases
This article explains the three‑stage encoding and decoding flow when inserting and retrieving data in MySQL, identifies why mismatched character sets cause garbled text, and shows how to ensure consistent charset settings across client, server, and tables.
GBKMySQLUTF-8
0 likes · 5 min read


ITPUBMar 21, 2017 · Databases
When moving data from Oracle to MySQL, Chinese characters may appear as garbled text because the server uses a latin1 charset; this guide explains three levels of fixes—table, database, and server—by configuring UTF‑8 settings and verifying the changes.
ChineseMySQLOracle
0 likes · 5 min read

This comprehensive guide walks you through MySQL's features, table size limits, Linux installation methods, source compilation, post‑install security hardening, character‑set management, engine selection, essential commands, and password recovery techniques for robust database administration.
ConfigurationLinuxMySQL
0 likes · 19 min read


ITPUBSep 21, 2016 · Databases
The article walks through a hands‑on experiment that shows how inserting the same Chinese string into an Oracle 10g database from clients using different character sets (ZHS16GBK vs AL32UTF8) leads to different stored encodings and results in garbled output, then explains the underlying conversion process and how to avoid it.
OracleSQLcharacter-set
0 likes · 13 min read


ITPUBAug 3, 2016 · Databases
This guide explains how to check the character set of an Oracle database and its client, demonstrates queries for server, instance, and session parameters, describes the risks of altering the server charset with ALTER DATABASE CHARACTER SET, provides safe conversion steps, and shows how to adjust client settings on Linux and Windows to avoid garbled Chinese text.
LinuxNLS_LANGOracle
0 likes · 11 min read


ITPUBJun 28, 2016 · Databases
This guide explains why Chinese characters appear as question marks in Sqlplus on Linux, how to identify the server character set, and provides step‑by‑step instructions to set the NLS_LANG environment variable and apply it instantly using the source command.
Database ConfigurationLinuxNLS_LANG
0 likes · 4 min read


21CTOOct 8, 2015 · Databases
This step‑by‑step guide shows how to completely remove any existing MySQL installation on Linux, reinstall it, and correctly configure the server and client character sets to UTF‑8, including version‑specific settings and verification.
Database ConfigurationLinuxMySQL
0 likes · 4 min read

This guide walks through locating MySQL's configuration file on Linux, copying a sample cnf, editing it to set default-character-set=utf8 for client and server, restarting MySQL, and verifying the change with SHOW VARIABLES, plus alternative methods via SQL commands and database options.
LinuxMySQLUTF-8
0 likes · 8 min read

This article explains Gecko's multi‑layer encoding detection, covering its state‑machine approach, character‑distribution analysis, 2‑byte sequence modeling, the overall detection workflow, and the table‑based conversion process that maps all encodings to Unicode.
Geckobrowser enginecharacter-set
0 likes · 14 min read
