I need some clarifications regarding the usage of StringToDecimal and DecimalToDecimal functions. I would really appreciate your help with regards to this. I have searched the forum on these functions, but unfortunately couldn't find anything related to my scenario...hence this post!
My scenario: My input is from a fixed width file. The amount fields are being read as Character datatypes.
Field-1: Char(3) Ex: 101
Field-2: Char(4) Ex: 1010
In the target table, which is DB2, the above amount fields are mapped to columns defined as Decimal {Col1: Decimal(7,5); Col2: Decimal(7,4)}
Field-1 ---> Col1
Field-2 ---> Col2
If I use StringToDecimal(Field-1) as a derivation into Col1 and similar definition for Col2, I am getting the warning:
Code: Select all
APT_CombinedOperatorController(3),1: Conversion error calling conversion routine decimal_from_ustring data may have been lost
APT_CombinedOperatorController(3),1: Conversion error calling conversion routine decimal_from_string data may have been lost
Can anyone clear this confusion of mine...
Thanks.