Need to convert the double data type precision of scale 1 to 2 in informatica cloud expression transformation

420 views Asked by At

My incoming field -->double datattype (veeva)--> for eg.s, 134.0 , 45.4,61.234 My output needs to be always 2 places of decimal --->file ---> field value: 134.00, 45.40, 61.23

I have tried creating an expression on informatica cloud: TO_DECIMAL( IN_TAX, 2 ) but its not giving the expected output.

1

There are 1 answers

2
Koushik Roy On

Keep the data type to double with decimal point =2 and use round(). I am assuming your target is a flat file.
create an out port in exp transformation like below -

out_tax = ROUND(in_tax,2)  -- data type is DOUBLE(xx,2), where xx is your precision. 

Link this port to target.