I use emojis in our project. our database had CHARACTER SET utf8. But emoji are not saved. Error:
CHARACTER SET utf8
1366 Incorrect string value: '\xF0\x9F\x98\x9C\xF0\x9F...'
alert database, datatable CHARSET=utf8mb4, column CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci. Before that, make sure mysql has a higher version than 5.5.3, you can use navicat for this
CHARSET=utf8mb4
CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci
change mysql configuration file, in windows it my.ini, in linux itmy.cnf
my.ini
my.cnf
[client] default-character-set = utf8mb4 [mysql] default-character-set = utf8mb4 [mysqld] character-set-server = utf8mb4 collation-server = utf8mb4_general_ci
delete characterEncoding=utf-8in properties file
characterEncoding=utf-8
restart mysql server
Source: https://habr.com/ru/post/1654331/More articles:Failed to establish a new connection: [Errno 111] Connection refused (elasticsearch) - python-2.7Pycharm expected type 'optional [bytes]' got 'str' instead - pythonAngular & Ionic, $ http does not work on a real Android device - angularjssingle column list to columns in R - rIs there a way to disable X-Frame settings from the URL of SSRS Report Manager? - tomcatCan I use the notification "com.apple.springboard.lockcomplete"? - iosCustom authentication method for Flask-Security - pythonpython SyntaxError: invalid syntax% matplotlib inline - pythonHow to use TextInputLayout with Theme.material? - javaRun Spark-shell with an error: SparkContext: SparkContext initialization error - hadoopAll Articles