debugsqlModerate
Error 1366: Incorrect string value: '\xF0\x9F\x98\x8A\x0AC…' for column 'text_body' at row 1
Viewed 0 times
incorrecterrorx98text_bodycolumnx9fvaluexf0x0acfor
Problem
I'm trying to store email content in mysql.
But i'm facing errors while trying to insert the row.
I have done some research and changed the column type to utf8mb4. But I'm still facing the problem.
Can someone tell me what i'm missing?
This is the error I'm getting
This is the character set of my table
But i'm facing errors while trying to insert the row.
I have done some research and changed the column type to utf8mb4. But I'm still facing the problem.
Can someone tell me what i'm missing?
This is the error I'm getting
Error 1366: Incorrect string value: '\xF0\x9F\x98\x8A\x0AC...' for column 'text_body' at row 1 This is the character set of my table
DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ciSolution
The
Also, the connection needs to be utf8mb4 (or
CHARACTER SET of the column needs to be utf8mb4. Please provide SHOW CREATE TABLE for confirmation.Also, the connection needs to be utf8mb4 (or
UTF-8, depending on the client language). Let's see the connection parameters.Context
StackExchange Database Administrators Q#161460, answer score: 11
Revisions (0)
No revisions yet.