Problems with German Characters

Discussion of open issues, suggestions and bugs regarding ODAC (Oracle Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
Strawberry
Posts: 4
Joined: Mon 22 Nov 2004 09:46

Problems with German Characters

Post by Strawberry » Mon 22 Nov 2004 09:57

Hello,
we use Delphi 7 with the ODAC NET Components. As Oracle Server we have the 9i Version with the Charset UTF8.
Now I have Problems with Insert and Update-Statements like this:
Insert into TBL_.. (ID, Name) VALUES (1, 'ÄÖÜ');
Update TBL_.. SET NAME = 'ÄÖÜ' Where ID = 1;
The Statements return no Error-Messages, but the Item Name is empty.
I got the same result with the Software HORA 6 from Keeptool. Their I know its a Delphi Project too.

:cry:
Thanks

the strawberry

Paul
Posts: 725
Joined: Thu 28 Oct 2004 14:06

Post by Paul » Mon 22 Nov 2004 14:57

TOraSession.Options.Charset property is essential when you work with UTF8 Oracle database. Please assign TOraSession.Options.Charset with a value correspondent to your national charset. Check also that TOraSession.Options.UseUnicode=False.

Strawberry
Posts: 4
Joined: Mon 22 Nov 2004 09:46

Post by Strawberry » Wed 24 Nov 2004 08:27

Hello Paul,

if I set the property UseUnicode to False I will get much more problems
with the length of my Databasefields, because the length of "Ä, Ö, Ü"
are more then 1.

Do you know a working charset for germany?

:(
Thanks

The Strawberry

Paul
Posts: 725
Joined: Thu 28 Oct 2004 14:06

Post by Paul » Thu 25 Nov 2004 08:28

You can pass this value using TOraParam objects. We supported national
encoding in parameters with Net option in ODAC 5.10.

OraQuery.SQL.Text:='Insert into TBL_.. (ID, Name) VALUES (1, :par1)';
OraQuery.ParamByName('par1').DataType:=ftWideString;
OraQuery.ParamByName('par1').ParamType:=ptInput;
OraQuery.ParamByName('par1').AsWideString:='AOU';

Strawberry
Posts: 4
Joined: Mon 22 Nov 2004 09:46

Post by Strawberry » Mon 27 Dec 2004 09:44

Hi Paul,

we have always the problems with the different charsets. We can
not always work with parameters. Their is also an problem with
the parameters, your solution works only onetime, if the procedure
runs the secondtime, it does not work. :cry:

If we work with the TOraQuery and the TOraUpdateSQL it works fine. 8)

What is different between the normal SQLStatement and the TOraUpdateSQL? :?

Thanks

Strawberry

Paul
Posts: 725
Joined: Thu 28 Oct 2004 14:06

Post by Paul » Tue 28 Dec 2004 07:39

Send us please small demo project to demonstrate the problem
and include script to create server objects to ODAC support address. Please specify ODAC version you have.

Strawberry
Posts: 4
Joined: Mon 22 Nov 2004 09:46

Post by Strawberry » Wed 29 Dec 2004 13:18

Hi Paul,

as I designed the testproject it worked fine. I have the Version
5.10.4.13.
Now it worked with the other projects too. :lol:
I set the option UseUnicode to False and now it works.
Before I had the problem if I set the option UseUnicode to False,
that the length of the DB-Field was to short.

But no it works fine. :lol:

What have changed in the new Version of
the Oracle Access Comp.?
Was their a change of the option UseUnicode? :?

Thanks

The strawberry

Post Reply