Page 1 of 1

Prefix a MINUS sign before a decimal number through trsfmr

Posted: Thu Oct 06, 2011 10:53 pm
by saraswati
Suppose there is a value 46.126523000000 in the source.

I want to truncate the value to two decimal values.

I used a transformer derivation DecimalToDecimal(lnk.AmtPosted,"round_inf") to truncate the values into two decimal values.

I want to have a minus before the value.

Now the output value is 46.13 .

I want it to be -46.13 .

Please let me know how can I implement it ?

Posted: Fri Oct 07, 2011 12:12 am
by suse_dk
multiply with -1

Posted: Fri Oct 07, 2011 12:21 am
by ray.wurlod
Multiply by -1 is definitely the easiest approach.

Posted: Fri Oct 07, 2011 8:18 am
by saraswati
Does anyone else has got some other idea for getting the MINUS sign before the decimal number?

Posted: Fri Oct 07, 2011 9:16 am
by ray.wurlod
Of course, but none as elegant as multiplying by -1.