Decimal data type is always converted to string (including in View Data) with leading and trailing non-significant zeroes. If you don't want them, you have to get rid of them, typically using a Trim() function.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
ray.wurlod wrote:Decimal data type is always converted to string (including in View Data) with leading and trailing non-significant zeroes. If you don't want them, you have to get rid of them, typically using a Trim() function.
Thanks Ray Wurlod.
But i still dont understand the following:
When my source field is Null. Why i am getting output as 'N' instead of getting ''(Nothing) in my target table after 2 transformers.
1st Transformer:
If isnull(col1) then '' else col1
2nd Transformer
If col= 1 Then 'Y' Else If col= 0 Then 'N' Else ''
seems like you are defaulting empty to a decimal field and thats why it is defaulting it to zero. Try varchar as datatype or default it to a decimal value or you can do intermediate calculations in stage variables.
Priyadarshi Kunal
Genius may have its limitations, but stupidity is not thus handicapped.
If you go to your source stage, double-click on the number at the left of the column or right-mouse click and "edit row" and then see if that column might have a default value set.
ArndW wrote:If you go to your source stage, double-click on the number at the left of the column or right-mouse click and "edit row" and then see if that column might have a default value set.