Question about Mysql database Chinese display

Source: Internet
Author: User

Struggling with elementary Web development, both hibernate and basic jdbc involve a coding problem. After all, this set of programming was invented by the foreign bank of lunjia. I had to bow my head in the Greater China Program, few gossip. Strictly speaking, three points:

1. Add two entries to the mysql configuration file my. ini. The default encoding is configured here when mysql is started.

[Client]

Default-character-set = UTF8 manually added)

[Mysqld]

Default-character-set = UTF8 manually added)

2. Enter the database:

-> D:

-> Cd mysql/bin

-> Mysql-u root-p

-> Enter the password.

-> Use Database Name

-> Show variable like 'character % '; (view the character set of the current database)

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131229/2054392A6-0.jpg "title =" 123.bmp "alt =" 151129731.jpg"/>

The first step should be like this. If not, then various sets will look like this.

For example:-> set character_set_client = utf8;

3. If the previous two steps still do not work, you may have encountered the same problem. We recommend that you download a database management software Navica to save time.

T650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131229/2054394I8-1.jpg "title =" tttt.bmp "alt =" 151505531.jpg"/>

The following table shows the design page:

650) this. width = 650; "src =" http://www.bkjia.com/uploads/allimg/131229/2054396013-2.jpg "title =" 1111111.bmp "alt =" 151749617.jpg"/>

You can modify the encoding of any field or directly operate the values in the database table here, which is very convenient for beginners to learn.


So far, I spent more than 24 hours searching for the three points that are really useful in Baidu, which is so vast that I hope it will be useful to later users. If you have the opportunity, you may want to use the most fundamental method to solve the encoding problem. However, as a cainiao, it is better to start from 0.




This article from the "Java practical development accumulation" blog, please be sure to keep this source http://yufenghang.blog.51cto.com/6014821/1300606

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.