Board index » delphi » problems with german language

problems with german language


2004-01-28 09:38:28 AM
delphi88
hi,
i had used the bde for my app but i get a strange error. all is fine but if
anyone type a char like ? ?or ?i don't get this char. instead i get for
the ?an char like a small b. changing the translitarate property didn't
helped. but, this is only in a tdbgrid. in a tdbedit it is right?! if i
change the tdbgrid to another grid component, i get the same problem.
now i have changed from bde to dbexpress in hope to avoid the problem an
uses a mysql db. and the problem is still the same! ok, now a take the mysql
console and let me show all datasets in the table. there it is stored
correctly! i need this char, but i always get this problem. its frustrating.
i use delphi 7, dbexpress and mysql 3.23.58
please help...
thx
bernhard mayer
 
 

Re:problems with german language

I had the same problems but the problem's source in my case was from the
windows installation. I guess that you do have a german windows version or
not?
The multilanguage version of the w2000 prof I work on, has specific problem
with the German characters on my pc. Still, I haven't found a solution. I
can;t even procees the German chars when I debug... and I work with German
regional settings.
On other PCs in the company, this works fine. But If I remember well, when I
installed the windows I chose the German reg.settings at the beggining. On
my PC I chose Greek and then changed to German... I guess it didn't work
well :-(
George Christoforakis.
 

Re:problems with german language

Hi Bernhard,
i am from Germany, so i know about your problem. I can give you a solution
which is based on BDE and an Interbase database. Maybe you can adopt that to
your MySQL and dbExpress environment.
The database had to have the setting
CREATE DATABASE "C:\projects\...." USER "SYSDBA" PASSWORD "masterkey"
PAGE_SIZE 1024 DEFAULT CHARACTER SET WIN1252;
SET NAMES WIN1252;
Your BDE database alias should have LANGDRIVER set to 'ascii' ANSII.
When having Select statements with "Order by" statements, be sure to specify
a collation order, otherwise your "Umlaute" will be sorted after "Z"
SELECT * FROM Customers ORDER BY Name COLLATE PXW_INTL
This will work regardless of the language of your operating system.
Harry
"Bernhard Mayer" <XXXX@XXXXX.COM>schrieb im Newsbeitrag
Quote
hi,

i had used the bde for my app but i get a strange error. all is fine but
if
anyone type a char like ? ?or ?i don't get this char. instead i get for
the ?an char like a small b. changing the translitarate property didn't
helped. but, this is only in a tdbgrid. in a tdbedit it is right?! if i
change the tdbgrid to another grid component, i get the same problem.
now i have changed from bde to dbexpress in hope to avoid the problem an
uses a mysql db. and the problem is still the same! ok, now a take the
mysql
console and let me show all datasets in the table. there it is stored
correctly! i need this char, but i always get this problem. its
frustrating.

i use delphi 7, dbexpress and mysql 3.23.58

please help...
thx
bernhard mayer


 

Re:problems with german language

well, i will try it, but my problem is not the database in mysql. the data
is stored absolutly correct with ??and ? its only the part who displays
the data. in my case the tdbgrid displays it wrong. the tdbedit did it
right?!
maybe any other ideas? could it be a bug in tdbgrid?
"Harald Feigel" <XXXX@XXXXX.COM>schrieb im Newsbeitrag
Quote
Hi Bernhard,

i am from Germany, so i know about your problem. I can give you a solution
which is based on BDE and an Interbase database. Maybe you can adopt that
to
your MySQL and dbExpress environment.

The database had to have the setting

CREATE DATABASE "C:\projects\...." USER "SYSDBA" PASSWORD "masterkey"
PAGE_SIZE 1024 DEFAULT CHARACTER SET WIN1252;

SET NAMES WIN1252;

Your BDE database alias should have LANGDRIVER set to 'ascii' ANSII.

When having Select statements with "Order by" statements, be sure to
specify
a collation order, otherwise your "Umlaute" will be sorted after "Z"
SELECT * FROM Customers ORDER BY Name COLLATE PXW_INTL

This will work regardless of the language of your operating system.

Harry


"Bernhard Mayer" <XXXX@XXXXX.COM>schrieb im Newsbeitrag
news:bv73q8$hol$04$XXXX@XXXXX.COM...
>hi,
>
>i had used the bde for my app but i get a strange error. all is fine but
if
>anyone type a char like ? ?or ?i don't get this char. instead i get
for
>the ?an char like a small b. changing the translitarate property didn't
>helped. but, this is only in a tdbgrid. in a tdbedit it is right?! if i
>change the tdbgrid to another grid component, i get the same problem.
>now i have changed from bde to dbexpress in hope to avoid the problem an
>uses a mysql db. and the problem is still the same! ok, now a take the
mysql
>console and let me show all datasets in the table. there it is stored
>correctly! i need this char, but i always get this problem. its
frustrating.
>
>i use delphi 7, dbexpress and mysql 3.23.58
>
>please help...
>thx
>bernhard mayer
>
>


 

Re:problems with german language

Have a look at the quality central (QC) if you can dig out any bugs
regarding this case.
George Christoforakis
"Bernhard Mayer" <XXXX@XXXXX.COM>writes
Quote
well, i will try it, but my problem is not the database in mysql. the data
is stored absolutly correct with ??and ? its only the part who displays
the data. in my case the tdbgrid displays it wrong. the tdbedit did it
right?!
maybe any other ideas? could it be a bug in tdbgrid?

 

Re:problems with german language

have solved the problem in my case. the grids columns fonts had an russian
charset and not the default. but i haven't changed it? its may be a bug in
dbexpress or dbgrid? i don't know, but now i have all ??and ?
thx to all
"Bernhard Mayer" <XXXX@XXXXX.COM>schrieb im Newsbeitrag
Quote
hi,

i had used the bde for my app but i get a strange error. all is fine but
if
anyone type a char like ? ?or ?i don't get this char. instead i get for
the ?an char like a small b. changing the translitarate property didn't
helped. but, this is only in a tdbgrid. in a tdbedit it is right?! if i
change the tdbgrid to another grid component, i get the same problem.
now i have changed from bde to dbexpress in hope to avoid the problem an
uses a mysql db. and the problem is still the same! ok, now a take the
mysql
console and let me show all datasets in the table. there it is stored
correctly! i need this char, but i always get this problem. its
frustrating.

i use delphi 7, dbexpress and mysql 3.23.58

please help...
thx
bernhard mayer


 

Re:problems with german language

I am fairly new to dbExpress and haven't have the time to face such a
problem. But my mother language is Greek so I will face it sometime.
So, here is an idea that is not tested yet :-/
When you save your data to the db use UTF8Encode() (UTF8 this is the latest
Unicode) to save it in UTF8 format. Then when you want to show it on the
screen you probably cannot because it has a Unicode format, so create a
calculated field and on the OnCalculate event use UTF8Decode() to tranform
the Unicode format to your native format.
Just one little note... UTF8 translates some characters to more than 1
bytes, so be prepared to have room for more characters than you normally
expect.
I hope this might work.
Alex
"Bernhard Mayer" <XXXX@XXXXX.COM>writes
Quote
hi,

i had used the bde for my app but i get a strange error. all is fine but
if
anyone type a char like ? ?or ?i don't get this char. instead i get for
the ?an char like a small b. changing the translitarate property didn't
helped. but, this is only in a tdbgrid. in a tdbedit it is right?! if i
change the tdbgrid to another grid component, i get the same problem.
now i have changed from bde to dbexpress in hope to avoid the problem an
uses a mysql db. and the problem is still the same! ok, now a take the
mysql
console and let me show all datasets in the table. there it is stored
correctly! i need this char, but i always get this problem. its
frustrating.

i use delphi 7, dbexpress and mysql 3.23.58

please help...
thx
bernhard mayer