Page 1 of 1

unicode SQL Text support

Posted: Fri 27 Apr 2007 02:01
by tkdsong
Hello.

How I can send query with unicode SQL Text.
For example:

OraQuery1.SQL.Text='
SELECT (unicode text - '한글') FROM table WHERE "compname"=:compname;


Where SELECT () is widestring.

If it`s not possible, what tricks I can use??

and, you said "ODAC does not support using Unicode strings in the SQL property of ODAC components."
Would you this support is not plain?

Posted: Fri 27 Apr 2007 07:45
by Plash
The SQL property of TOraQuery should contain text in the character set that is set in the NLS_LANG parameter from the Windows registry or environment variable.
If the character set in the NLS_LANG parameter is the same as your Windows non-Unicode character set, and '한글' characters are present in the Windows non-Unicode character set, you can use these characters in the SQL property.

We'll consider possibility to support Unicode in the SQL property in either of the next ODAC versions.

Re: unicode SQL Text support

Posted: Tue 06 Nov 2012 07:57
by BenSteiner
Hello Devart Team,

will you implement the unicode support for the sql.text property or not?
I still tried the version 8 of odac and it is not working there.

Sincerely
Benjamin Steiner

Re: unicode SQL Text support

Posted: Tue 06 Nov 2012 13:07
by AlexP
Hello,

To make such query work, you should set the UseUnicode option and OCIUnicode (declared in OraCall) to True

Code: Select all

uses ..., OraCall;
....
  OCIUnicode := true;
  OraSession1.Connect;
  OraQuery1.SQL.Text := 'SELECT  ''한글'' FROM DUAl';
  OraQuery1.Open;

Re: unicode SQL Text support

Posted: Wed 07 Nov 2012 07:32
by BenSteiner
Hello,

i will try this.

Thank you for your Help.

Re: unicode SQL Text support

Posted: Wed 07 Nov 2012 08:02
by BenSteiner
It works :)

Re: unicode SQL Text support

Posted: Wed 07 Nov 2012 08:17
by AlexP
hello,

Glad to see that the problem was solved. If you have any other questions, feel free to contact us.