S
S
Silver_Clash2012-04-18 22:24:28
MySQL
Silver_Clash, 2012-04-18 22:24:28

[SOLVED] Toad for MySQL, how to make friends with Cyrillic?

I haven't picked up checkers for a long time...

On a Windows 7 machine, there is MySQL server 5.5, a database with tables in utf8_unicode_ci, and Toad for MySQL 6.0.1.

When executing queries with the insertion of Cyrillic from the toad, all Russian letters are replaced by '?????'.
With Cyrillic bets from the console, and output in the console, everything is fine.
When inserting Cyrillic from the console, and outputting through a toad or a php application, incomprehensible hieroglyphs.

SHOW GLOBAL VARIABLES LIKE 'char%'; 

He speaks:
| character_set_client     | latin1
     |
| character_set_connection | latin1
     |
| character_set_database   | latin1
     |
| character_set_filesystem | binary
     |
| character_set_results    | latin1
     |
| character_set_server     | latin1
     |
| character_set_system     | utf8


The real question is how to fix this mess?

UPD: After changing latin1 to utf8 in the server settings (my.ini), the following picture turned out:

| character_set_client     | utf8
     |
| character_set_connection | utf8
     |
| character_set_database   | utf8
     |
| character_set_filesystem | binary
     |
| character_set_results    | utf8
     |
| character_set_server     | utf8
     |
| character_set_system     | utf8


At the same time, the toad inserts the Cyrillic alphabet, receives the Cyrillic alphabet in the query results, now everything is ok in the application, but only hieroglyphs appear in the console (SET NAMES does not save). When I try to update with Cyrillic from the console, I get the following result:

mysql> update table set var = 'абв' where id=1;
ERROR 1366 (HY000): Incorrect string value: '\xA0\xA1\xA2' for column 'var'
at row 1


In general, I can do without a console, but the sports interest has not yet passed. Maybe someone knows how to make the Cyrillic alphabet work everywhere?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
ssbxlan, 2012-04-19
@Silver_Clash

So the console font can be changed to utf

A
Alexey Sundukov, 2012-04-18
@alekciy

www.google.com/search?q=set+names&ie=utf-8&oe=utf-8&aq=t&rls=org.mozilla :en:official&client=firefox

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question