mysql client does not display utf8 characters correctly
Posted by:
Andi Meier
Date: December 13, 2006 03:13PM
When I launch the mysql client (4.1) and do
select char(246);
the result is:
mysql> select char(240);
+-----------+
| char(228) |
+-----------+
| � |
+-----------+
1 row in set (0.00 sec)
Awkward! I would have expected:
+-----------+
| char(228) |
+-----------+
| ä |
+-----------+
My settings:
---------------------------------------------------------
mysql> \s
--------------
mysql Ver 14.7 Distrib 4.1.11, for pc-linux-gnu (i386)
Connection id: 17
Current database: idioms
Current user: root@localhost
SSL: Not in use
Current pager: less
Using outfile: ''
Using delimiter: ;
Server version: 4.1.11-Debian_4sarge7-log
Protocol version: 10
Connection: Localhost via UNIX socket
Server characterset: latin1
Db characterset: utf8
Client characterset: utf8
Conn. characterset: utf8
UNIX socket: /var/run/mysqld/mysqld.sock
Uptime: 1 hour 34 min 37 sec
Threads: 2 Questions: 137 Slow queries: 0 Opens: 27 Flush tables: 1 Open tables: 9 Queries per second avg: 0.024
---------------------------------------------------------
Of course, the main problem is not this simple query, but that the content of my tables (containing UTF8 characters like german umlauts) is displayed incorrectly, showing up these unreadable Unicode character strings.
Any help greatly appreciated! After searching hours via Google and mysql forums I could not find any working answer to my problem.
Andi
Subject
Views
Written By
Posted
mysql client does not display utf8 characters correctly
4548
December 13, 2006 03:13PM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.