Author |
Message
|
Shahid.Hussain |
Posted: Tue Sep 28, 2010 9:49 am Post subject: Problem in database node |
|
|
Novice
Joined: 18 Mar 2009 Posts: 13
|
Hi,
i m having the following problem. i am accessing oracle from database node using ODBC connection. when i executes the following statement i get white square (□) after every character of data. for example if row contain 050 in variable i am getting 0□5□0□.
here is the code to execute the query.
SET Environment.Variables.Result[] = (select fld1 from tbl1 where fld1=1)
i have checked in the oracle tables data is in correct format. (i mean without white square)
one more thing i did. i created small vb application to get the data from same source. it is showing correctly.
can any one help on this.
thanks & regards
Shahid Hussain |
|
Back to top |
|
 |
lancelotlinc |
Posted: Tue Sep 28, 2010 10:02 am Post subject: |
|
|
 Jedi Knight
Joined: 22 Mar 2010 Posts: 4941 Location: Bloomington, IL USA
|
|
Back to top |
|
 |
Vitor |
Posted: Tue Sep 28, 2010 10:31 am Post subject: Re: Problem in database node |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Shahid.Hussain wrote: |
one more thing i did. i created small vb application to get the data from same source. it is showing correctly.
|
If it's VB.NET then that's probably using a double byte character set like your database seems to be doing.. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
Shahid.Hussain |
Posted: Wed Sep 29, 2010 8:44 am Post subject: |
|
|
Novice
Joined: 18 Mar 2009 Posts: 13
|
is there any way to convert double byte character to single byte character in esql ?? |
|
Back to top |
|
 |
lancelotlinc |
Posted: Wed Sep 29, 2010 9:00 am Post subject: |
|
|
 Jedi Knight
Joined: 22 Mar 2010 Posts: 4941 Location: Bloomington, IL USA
|
|
Back to top |
|
 |
mqjeff |
Posted: Wed Sep 29, 2010 9:00 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
Do you have an NLS_LANG environment variable set in the shell that is running Broker?
The Oracle and or ODBC connection should be handling any of this character conversion for you.
But the real question is - exactly what are you using to display the data? |
|
Back to top |
|
 |
Vitor |
Posted: Wed Sep 29, 2010 9:01 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Shahid.Hussain wrote: |
is there any way to convert double byte character to single byte character in esql ?? |
No, and the question is irrelevant. Within ESQL (i.e. inside the broker) the message tree is double byte Unicode & nothing you can do will change that. This ensures that broker can handle internally any character.
The question you meant to ask is, 'can WMB convert double byte input to single byte output?' and the answer is yes. It's not an ESQL function for the reason I gave above, but concerns the code page you instruct broker to use when converting it's internal tree to whatever you want it to output.
There have been many, many discussions on this surprisinging complex and fraught topic. The search facility is your friend here; start by looking for "code page", "CCSID" and the posts of kimbert. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
rekarm01 |
Posted: Sun Oct 03, 2010 4:00 am Post subject: Re: Problem in database node |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 1415
|
Shahid.Hussain wrote: |
i am accessing oracle from database node using ODBC connection. |
To properly configure the database and odbc drivers for Unicode support, check the broker documentation:
Quote: |
If you are using Oracle:- Your database must be created with NLS_CHARACTERSET of AL32UTF8.
- Your ODBC data source definition must include the setting ColumnSizeAsCharacter=1 ...
- For 32-bit connections, you must set the variable NLS_LANG in the broker environment to the value <yourlanguage>_<yourterritory>.AL32UTF8.
|
|
|
Back to top |
|
 |
klausfelix |
Posted: Mon Apr 04, 2022 10:04 pm Post subject: |
|
|
Newbie
Joined: 04 Apr 2022 Posts: 3
|
I am having the following problem.
I am accessing oracle from database node using ODBC connection. |
|
Back to top |
|
 |
klausfelix |
Posted: Mon Apr 04, 2022 10:05 pm Post subject: |
|
|
Newbie
Joined: 04 Apr 2022 Posts: 3
|
when i executes the following statement i get white square (□) after every character of data.
For example if row contain 050 in variable i am getting 0□5□0□.
SET Environment.Variables.Result[] = (select fld1 from tbl1 where fld1=1)
i have checked in the oracle tables data is in correct format.
One more thing i did. i created small vb application to get the data from same source. it is showing correctly. |
|
Back to top |
|
 |
klausfelix |
Posted: Mon Apr 04, 2022 10:07 pm Post subject: |
|
|
Newbie
Joined: 04 Apr 2022 Posts: 3
|
Do you have an NLS_LANG environment variable set in the shell that is running Broker.
The Oracle and or ODBC connection should be handling any of this character conversion for you.
But the real question is - exactly what are you using to display the data.
First Motion Products |
|
Back to top |
|
 |
timber |
Posted: Tue Apr 05, 2022 4:00 am Post subject: |
|
|
 Grand Master
Joined: 25 Aug 2015 Posts: 1292
|
You have quoted the first post on this thread (from 2010!) and mqjeff's answer. It would be better to open a new thread, and link to this thread from the new thread.
You have not explained what you have tried, so it is difficult to provide any help. |
|
Back to top |
|
 |
|