How to make Windows command line display UTF-8 characters

Source: Internet
Author: User


I 've been worried about how to display UTF-8 characters on Windows terminals. For example, in the MySQL command line, if the database encoding is UTF-8, then, when querying the database, the Chinese inside will become garbled. Today, I searched for it unintentionally and found that the solution is very simple: 1. Modify the terminal code page. Enter: chcp 650012 in the terminal. right-click the terminal on the taskbar (or click the icon in the upper-left corner of the window), select Properties From the shortcut menu, and select a font, such as Lucida Console. Do not select a dot matrix font "; after confirming, test the UTF-8 output again, what you see. :) Switching back to the original mode is also easy: just change the font of chcp 936 to the original dot matrix font. Note: After the code page is modified, if you use Cygwin, you will find that the ls-show-control-chars command of cygwin encounters an error in the Chinese directory name. This article is from Venj's Wikipedia

Related Article

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.