Unicode support in c api
Posted by: Einav Itamar
Date: September 17, 2007 06:16AM

Hi,
I'm trying to insert a unicode string to mysql through c API.
the default character set is utf8.
I created a table:
CREATE TABLE uni3 (u VARCHAR(255) CHARACTER SET utf8 NOT NULL) DEFAULT CHARSET=utf8;

and then connected from c api.
I also execute "set names utf8" after I connect.
Still, I'm trying to insert utf8 string:
mysql_real_query(&mysql,"INSERT INTO UNI3 SET U=_utf8'\x05\xd9';",33);
and get an error message
"Incorrect string value: '\xD9' for column 'u' at row 1"

Can anyone please help me???

Thanks,
Einav

Options: ReplyQuote


Subject
Views
Written By
Posted
Unicode support in c api
4299
September 17, 2007 06:16AM


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.