MySQL Forums
Forum List  »  Delphi

Problem with Delphi for Win32 / ADO / MySQL and utf8 characters
Posted by: Angelin Lalev
Date: December 08, 2007 12:22PM

I cannot get UPPER() function to work correctly in
SQL queries, sent from Delphi application. More exactly:
1. All occurrences of the cyrillic lowercase letter "CHE" (0x0447) are not transposed to its uppercase equivalent (0x0427).
2. All occurrences of cyrillic lowercase letter "YA" (0x044F) are transposed to
cyrillic lowercase letter "DZHE" (0x045F) instead of cyrillic uppercase letter "YA" (0x042F).

At first I tought that it's a bug in mysql server, but a test from php application showed none of these problems. Then I issued show variables from a test delphi application and got the following results:

...
character_set_client latin1
character_set_connection latin1
character_set_database utf8
character_set_filesystem binary
character_set_results latin1
character_set_server utf8
...

At that point I tried to add CHARSET=UTF8 to my connection string
and the values of the above variables became

...
character_set_client utf8
character_set_connection utf8
character_set_database utf8
character_set_filesystem binary
character_set_results utf8
character_set_server utf8
...

Unfortunatelly, at that point all my queries returned garbage in the places of
the cyrillic symbols.

What shoud I do. Is that a known problem and are there ways to overcome it.
It's not that critical, because except than 1 and 2 everything works
fine with latin1 for the result set. But it's annoying ....

Options: ReplyQuote


Subject
Written By
Posted
Problem with Delphi for Win32 / ADO / MySQL and utf8 characters
December 08, 2007 12:22PM


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.