Troubleshooting of MySQL errors: Difference between revisions
Jump to navigation
Jump to search
+ ERROR 1366: Incorrect string value
(+ ERROR 1366: Incorrect string value) |
|||
| Line 209: | Line 209: | ||
* Check the database 'MY_DATABASE_p' is exists | * Check the database 'MY_DATABASE_p' is exists | ||
* Check there are no {{kbd | key=TAB}} character after database name if you want to connect the database 'MY_DATABASE' when you are using console. | * Check there are no {{kbd | key=TAB}} character after database name if you want to connect the database 'MY_DATABASE' when you are using console. | ||
== ERROR 1366: Incorrect string value == | |||
Message: SQLSTATE[HY000]: General error: 1366 Incorrect string value: '\xF0\x9F\x87\xAF\xF0\x9F...' for column 'XXX' | |||
Solution: | |||
* Check the charset of PHP PDO. AND execute {{kbd | key=set names utf8mb4}}<ref>[https://stackoverflow.com/questions/54947392/incorrect-string-value-when-trying-to-pass-emoji-to-the-db-encoded-with-utf8mb4 php - Incorrect string value when trying to pass emoji to the db encoded with utf8mb4 - Stack Overflow]</ref> | |||
== Error!: SQLSTATE[28000]: Invalid authorization specification: 1045 Access denied == | == Error!: SQLSTATE[28000]: Invalid authorization specification: 1045 Access denied == | ||