Character Set Diagnosis

Current MySQL Connection Settings

VariableValue
character_set_clientutf8mb4
character_set_connectionutf8mb4
character_set_databaseutf8mb4
character_set_filesystembinary
character_set_resultsutf8mb4
character_set_serverutf8mb4
character_set_systemutf8mb3

Current Collation Settings

VariableValue
collation_connectionutf8mb4_0900_ai_ci
collation_databaseutf8mb4_0900_ai_ci
collation_serverutf8mb4_0900_ai_ci

Emails Table Structure

FieldTypeNullKeyDefaultExtra
idintNOPRINULLauto_increment
eact_idintYESUNINULL
activity_idintYESNULL
emen_idintYESMULNULL
entity_namevarchar(255)YESMULNULL
subjectvarchar(255)YESNULL
from_addressvarchar(255)YESMULNULL
to_addresstextYESNULL
cc_addresstextYESNULL
bcc_addresstextYESNULL
bodytextYESNULL
body_htmlmediumtextYESNULL
date_createddatetimeYESMULNULL
date_sentdatetimeYESNULL
date_receiveddatetimeYESNULL
directionvarchar(20)YESNULL
statusvarchar(50)YESNULL
importancevarchar(20)YESNULL
message_idvarchar(255)YESMULNULL
thread_idvarchar(255)YESMULNULL
has_attachmentstinyint(1)YES0
attachment_countintYES0
attachment_detailstextYESNULL
tagstextYESNULL
creator_idvarchar(255)YESNULL
creator_namevarchar(255)YESNULL
assignee_idvarchar(50)YESNULL
assignee_namevarchar(255)YESNULL
raw_datalongtextYESNULL
sync_timestamptimestampYESCURRENT_TIMESTAMPDEFAULT_GENERATED
last_updatedtimestampYESCURRENT_TIMESTAMPDEFAULT_GENERATED on update CURRENT_TIMESTAMP

Emails Table Status

NameEngineCollationRowsSize
emailsInnoDButf8mb4_unicode_ci3851971942144

Email Subject Column Information

FieldTypeCollationNullKeyDefaultExtraPrivilegesComment
subjectvarchar(255)utf8mb4_unicode_ciYESNULLselect,insert,update,referencesEmail subject

Test and Fix

Test inserting an emoji into the emails table:

Fix connection character set (use if your connection isn't using utf8mb4):

Important Note

For permanent fixes:

  1. Edit your db.class.php file to change:
  2. $this->db_connection->set_charset("utf8");

    to:

    $this->db_connection->set_charset("utf8mb4");
  3. If your database connection settings still show "utf8" instead of "utf8mb4" after doing this, you may need to restart your web server.