>-----Original Message----- >From: ?? [mailto:tyzha...@gmail.com] >Sent: Thursday, April 21, 2011 7:09 AM >To: mysql >Subject: mysql deal with specail character problem > >Hi: >I have a table that the field a is primary key; >I insert a record like this >insert into table(a,b,c) values('?????',1,1) >Then i insert a record like this > insert into table(a,b,c) values('?????',1,1) > >mysql post a error execute failed: Duplicate entry '?????-1-1' for key 1; > >it is strange, the primary key field is not the same, but i get this error. > >any one can help me? > [JS] What is the character set and collation for that field? Please post the output of
SHOW CREATE TABLE x\G (Please use the \G, so that the output will fit in your message better.) There is something wrong with the way your data is going in, because the commas are not being seen properly. You are putting in '?????',1,1 but MySQL is showing '?????-1-1' in the error message! That is a clue. I have put plenty of Japanese and Chinese characters into my database, so don't give up hope. >Thanks -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/mysql?unsub=arch...@jab.org