OCI_INVALID_HANDLE with NLS Mapping

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Not necessarily an NLS issue, at least not yet. Any chance you are moving any kind of "LOB" data in the job? It is not supported and can generate that error, hence the question.
-craig

"You can never have too many knives" -- Logan Nine Fingers
userasif
Participant
Posts: 50
Joined: Tue Jun 06, 2006 5:57 am

Post by userasif »

In source data type for this column is varchar2(240)... Not "LOB". Also I have tried with LongVarchar data type but same error.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Re: OCI_INVALID_HANDLE with NLS Mapping

Post by ArndW »

userasif wrote:...If I use NONE for NLS Mapping for source stage then job finished is OK but data is not in Arabic form...
Just to be certain, how do you determine that the output isn't correct? Do not use the "view data" functionality to do this.
userasif
Participant
Posts: 50
Joined: Tue Jun 06, 2006 5:57 am

Post by userasif »

ArndW, I am not using "View data" functionality but in SQL Plus also it shows "???????????" for this data. The same data in other application is in Arabic form.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Best use a tool which shows you the hex values for each character. "?" could be either a real question mark or it could mean an undisplayable character (using the session's NLS settings). What is the HEX or Decimal value of the first '?' character in the string?
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Invalid handle usually indicates some kind of connectivity problem, rather than any kind of data problem.

That said, I will almost guarantee that you can not use a Russian map to move Arabic data.

Character maps do NOT perform translation!
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
userasif
Participant
Posts: 50
Joined: Tue Jun 06, 2006 5:57 am

Post by userasif »

The HEX value for first ? is 203F. Also this is the same HEX value for this data in source database. English data in source db is fine but Arabic data in source db is like '????". My concern is to get these question marks to be translated in Arbaic because these are Arabic data.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

And what value was that character (again in HEX) in the source?

0x20 3F isUndertie in Unicode.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

As Ray has already stated, are you sure that your selected character sets are correct? Is the arabic data in your source perhaps already stored correctly and by trying to convert from Russian to Arabic you are actually corrrupting the data?
userasif
Participant
Posts: 50
Joined: Tue Jun 06, 2006 5:57 am

Post by userasif »

Are you sure that your selected character sets are correct?
I am not sure about the Russian character set to be used in DataStage but I am using KOI8-R.
Also problem occurs with input stage NLS Mapping.
Is the arabic data in your source perhaps already stored correctly?
Yes, because the same source data display is in Arabic in Oracle Forms application.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Since RU8PC866 does not contain mappings for arabic characters but you stated that they are visible in the source, you are essentially corrupting your data by mapping it from KOI8-R during your initial read. This stage needs to be told that the incoming data is already in AR8MSWIN1256
userasif
Participant
Posts: 50
Joined: Tue Jun 06, 2006 5:57 am

Post by userasif »

I have tried it with MS1256 but same error. Also I have tried with UTF-8 and ohter as an hit and trial method but same error for all NLS Map selection except NONE.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

I think you are trying too much at once. Reduce the problem to the read portion, just read the data and then write to a sequential file. Ensure you choose the right mapping for your source - once that works, you can add complexity.
userasif
Participant
Posts: 50
Joined: Tue Jun 06, 2006 5:57 am

Post by userasif »

ArndW sorry... Following error when output is Sequential File.
"Attempting to Cleanup after ABORT raised in stage".
Also with NONE NLS Map in Source stage...job is sucessful but data is written in question marks "?????" to text file. I have changed the text file to UTF-8 but same "?????????????"
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

Remember that a "?" mark might be an undisplayable character, so you will need to produce the hex equivalent. Start with the source - what is the hex value of the first character. Then check the same character in the sequential file. If you maps are NONE then they will be identical. If both your source and target maps are arabic, the values should be the same as well.
Post Reply