Unicode trouble (five days spent)
Posted: Fri 25 Mar 2005 17:17
Hello, Core Lob!
We use now ODAC VCL 4.5 and have to support Unicode in our database.
Database
create table BA_DOMAIN_STRING
(
Hello, Core Lob!
We use now ODAC VCL 4.5 and have to support Unicode in our database.
Database
create table BA_DOMAIN_STRING
(
CODE VARCHAR2(255) not null,
DOMAIN_CD VARCHAR2(255) not null,
LANG_CD VARCHAR2(10) not null,
NAME NVARCHAR2(500) not null
)
Oracle Server 9.2
Oracle Client 9.2
Code
Delphi 6.0
TOraSql.Text=
'INSERT INTO BA_DOMAIN_STRING
("CODE", "DOMAIN_CD", "LANG_CD", "NAME")
VALUES
(:"CODE", :"DOMAIN_CD", :"LANG_CD", :"NAME")'
TOraSession.Options.UseUnicode= true;
All parametrs have type ftWideString
I have tested
1) TOraSql.Params.Value=SomeWideString
2) TOraSql.Params.Value=SomeOleVariant
3) TOraSql.Params.AsWideString=SomeWideString
4) TOraQuery instead TOraSql
5) TOraLoader
6) Download trial version 5.50.0.16 for Delphi 6 and test on 1-4 it
All SomeWideStrings and SomeOleVariants I have wrote to text file (to debug).
It looks fine, but I see in field "Name" only "????????????" (upsided down) instead arabian chars.
My viewer works correct (it was checked on another non-delphi project).
What I have to do?
Or ODAC VCL does'nt support unicode and I have to try another solution?;)
Best Regards,
Serg Soorskih
We use now ODAC VCL 4.5 and have to support Unicode in our database.
Database
create table BA_DOMAIN_STRING
(
Hello, Core Lob!
We use now ODAC VCL 4.5 and have to support Unicode in our database.
Database
create table BA_DOMAIN_STRING
(
CODE VARCHAR2(255) not null,
DOMAIN_CD VARCHAR2(255) not null,
LANG_CD VARCHAR2(10) not null,
NAME NVARCHAR2(500) not null
)
Oracle Server 9.2
Oracle Client 9.2
Code
Delphi 6.0
TOraSql.Text=
'INSERT INTO BA_DOMAIN_STRING
("CODE", "DOMAIN_CD", "LANG_CD", "NAME")
VALUES
(:"CODE", :"DOMAIN_CD", :"LANG_CD", :"NAME")'
TOraSession.Options.UseUnicode= true;
All parametrs have type ftWideString
I have tested
1) TOraSql.Params.Value=SomeWideString
2) TOraSql.Params.Value=SomeOleVariant
3) TOraSql.Params.AsWideString=SomeWideString
4) TOraQuery instead TOraSql
5) TOraLoader
6) Download trial version 5.50.0.16 for Delphi 6 and test on 1-4 it
All SomeWideStrings and SomeOleVariants I have wrote to text file (to debug).
It looks fine, but I see in field "Name" only "????????????" (upsided down) instead arabian chars.
My viewer works correct (it was checked on another non-delphi project).
What I have to do?
Or ODAC VCL does'nt support unicode and I have to try another solution?;)
Best Regards,
Serg Soorskih