Inserting Gujarati text into a MySQL tables results in junk characters and unreadable text

给你一囗甜甜゛ 提交于 2019-12-09 05:39:36

问题


I have three MySQL tables and I'm inserting Gujarati content into them. When I insert two tables, they're inserted fine and are readable but in one table, it is showing junk characters/unreadable text. How can I fix this?


回答1:


MySQL has per-table character set settings.

You can check which character set you are using for each table - see How do I see what character set a MySQL database / table / column is?.

If that is your problem, you might be able to covert the table in question, using:

ALTER TABLE mytable CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;



回答2:


Just you have to like ...

in Your Mysql DataBase Table.. Just Change 'Collation' of column Name. To 'utf8mb4_general_ci'.

and you can store any Gujarati font in database



来源:https://stackoverflow.com/questions/10996460/inserting-gujarati-text-into-a-mysql-tables-results-in-junk-characters-and-unrea

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!