Re: Weird utf-8 encoding problem using webserver that does not occur in command line client
Posted by: Rick James
Date: July 02, 2009 07:45AM

Interesting puzzle.
Perhaps it assumes the CHAR(...) is just a bunch of bytes, yet the substr is delivering utf8.

Ponder this:
mysql> SELECT CHAR_LENGTH(CONVERT(CHAR(50603) USING utf8));
+----------------------------------------------+
| CHAR_LENGTH(CONVERT(CHAR(50603) USING utf8)) |
+----------------------------------------------+
|                                            1 |
+----------------------------------------------+
and let me know if that helps solve your puzzle.

Options: ReplyQuote




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.