Page 1 of 1

truncating varchar field

Posted: Mon Mar 19, 2007 9:45 am
by Mallayagari
Hi
I am writing a large varcharfield(2000) to a sequential file(fixed widh) but its truncating the value and writing. Is there any limitation on varchar field or fixed width file??


Thanks in advance

Posted: Mon Mar 19, 2007 11:42 am
by DSguru2B
What do you mean its truncating? Is it truncating the data (can you confirm by doing a head at the unix level) or truncating the length? If you want to honor the length then specify the field as char.

Posted: Mon Mar 19, 2007 12:11 pm
by Krazykoolrohit
There are no limitation as far as i know and if there is such a thing its not 2000 definetly.

Post an example how you feel the data is getting truncated

Posted: Tue Mar 20, 2007 5:27 am
by Sainath.Srinivasan
Varchar and fixed width?

There must be some place where you fix the length in output.

Size in the target

Posted: Tue Mar 20, 2007 9:57 am
by novneet
Is there any field size you have defined in the target sequential file?
If No, then it takes the default size of the varchar as 1024.

Posted: Tue Mar 20, 2007 10:10 am
by Sreedhar
As per your question about the limit of varchar is concern it can handle up to 32,672 characters in length.

Do check what you have given in the target.

Also check what is the display value you have given in the metadata of the source.

These two check should help you to resolve the prob.

Do let us know your finding, which would help the entire dsxchange group.