Hi András,
Thanks for the explanation, I will try the SET NAMES to export my XML file
in utf8 (I actually want it to be in utf8)
I'm sorry if this is a basic question, but as I said before I'm kind of lost
with the encodings....
From what you tell me, if the client utf8 send data to mysql isolatin1,
there is no conversion done, and mysql will stil be happy to export utf8 (if
asked to do so with a set names). So what is the role of the character set
and collation at the database level?From what I understand the collation is
used when you want to order results for example, case sensitive or not for
example.Is that correct and then what is the character set used for?
I'm building a new database with utf8 to be able to store chinese and
cyrillic characters, and I will probably have to change that old isolatin1
to utf8 as well, but i'd like to understand what I'm doing....
thanks for your help,
melanie
If you write an hungarian article about your test, maybe you will plan an
english translation?or is hungarian hard to learn? :-)
From: BÁRTHÁZI András <[EMAIL PROTECTED]>
To: mel list_php <[EMAIL PROTECTED]>
CC: mysql@lists.mysql.com
Subject: Re: character sets.....(missing info)
Date: Tue, 08 Nov 2005 19:55:30 +0100
Hi,
if the character_set_client is by default latin1, does that mean that the
java application is sending latin1?or is it changed at runtime?
kind of lost again.....
As I understand, the charset of the column/table/database is irrelevant,
there will be no conversion if you query from or insert into the table.
There *is* conversion, but it depends on the communication settings - and
it is detailed in the documentation. The character_set_* variables are your
friend: *_client, *_connection and *_results as I know.
If you want to solve your problem, then just run a "set names utf8" SQL
query before querying the data for the *XML* file, and you will get the
data in UTF-8. Or just put a header into the XML file that says your data
in Latin1 (I think it's not so easy in Java).
Anyway, I don't know, how Java handles the character sets related to MySQL
at the client side, but it works well for the console and for PHP and Perl
clients.
Bye,
Andras
ps: The column charset will be used for collations, and maybe for string
functions, as I know. I'm planning to test it to make sure, and write a
Hungarian article about it, but I think you won't be happy with it. :)
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:
http://lists.mysql.com/[EMAIL PROTECTED]
_________________________________________________________________
Be the first to hear what's new at MSN - sign up to our free newsletters!
http://www.msn.co.uk/newsletters
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]