implicit conversion from source type "string" to result type "string[max=4]": Possible truncation of variable length string.
The stuff is its taking string without any length and converting it to a string of a particular length.
When i explicitly specify the length then also it throws warning as
It doesn't have enough room for holding the decimal say when i give string[12] for decimal[11,0].When i inrease the length of the string then it shows the First said truncation warning . How shall i avoid these Possible truncation warnings and not enough room for holding decimal warnings .
Please help ....
The string for a decimal needs to have at least two more character positions than the precision of the decimal data type, one for the decimal placeholder character and one for the sign character (which may be a space).
When converting from an unbounded string to a bounded string (for example string to string[max=4]) there is no way to avoid the alert, because DataStage wants to alert you to the possibility of lost data - even though you might be using a Left() function or similar - it's test is done purely on the metadata (record schema). In this case, the only option seems to be a message handler to demote the severity of the logged message.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Hi ,
As said i have added some more length into the string but it still throws truncation warning ie Possible truncation of string[14] to string[12]. The output tab holds the metadata as string[12]( This is the metadata that the target table has)