Truncation of data for varchar field while using ODBC stage.

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

ujala
Participant
Posts: 45
Joined: Mon Jun 21, 2010 2:51 pm
Location: Chennai

Post by ujala »

Yes, integer values come across the ODBC interface correctly.

As mentioned earlier i am facing problem only with varchar fields.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

That is quite strange behaviour indeed. If you write to your table then capture the display the value to a file for a known string, i.e. "ABC" then do an od -x on just the first character shown, what is the value? We need to know the expected value of the first character "A" and the resulting representation in order to guess what might be happening.
venkateshrupineni
Participant
Posts: 15
Joined: Wed May 02, 2012 3:38 am

Post by venkateshrupineni »

i may thought it may be the issue with Length of column or NLS try to change the length and check it once...

other try to use cast function and increase your length of your truncate clumn at the source level and passed that changed value to further stages..try this ...
ujala
Participant
Posts: 45
Joined: Mon Jun 21, 2010 2:51 pm
Location: Chennai

Post by ujala »

sorry but i didnot get it.

Can u specify in detail
ujala
Participant
Posts: 45
Joined: Mon Jun 21, 2010 2:51 pm
Location: Chennai

Post by ujala »

Ran the job Changing the length and NLS and also used cast function but same result..

I am getting only the first character in the output.
ArndW
Participant
Posts: 16318
Joined: Tue Nov 16, 2004 9:08 am
Location: Germany
Contact:

Post by ArndW »

You still aren't answering the important questions. Again - what is the first character of the string supposed to be and what is the ascii code of the first character coming out.
ujala
Participant
Posts: 45
Joined: Mon Jun 21, 2010 2:51 pm
Location: Chennai

Post by ujala »

found a work around - if i use ODBC stage instead of ODBC connector, it works fine
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Then it seems to me that you should report this to your official support provider.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply