Skip to main content

Hello FME community,

 

I have a long number (see the picture). I want only up to 3 decimal places to be displayed.

 

the nummberThanks in advance for your help

 

Hi

You can use the attribute rounder transformer for this. Set the decimal to 3. However I think your problem is that your data has the wrong delimiter, FME uses a full stop as the decimal delimiter instead of the comma.

So if the attribute rounder doesn't seem to work for you it is probably because FME thinks that your attribute is a string instead of a number.

 


Hi

You can use the attribute rounder transformer for this. Set the decimal to 3. However I think your problem is that your data has the wrong delimiter, FME uses a full stop as the decimal delimiter instead of the comma.

So if the attribute rounder doesn't seem to work for you it is probably because FME thinks that your attribute is a string instead of a number.

 

Thanks alot

 


Another solution would be to use the string formatter. In this example my number is 0.123456 and I want it to only display 3 places past the decimal. I will use the format string of .3f to do this.

0.123456 -> 0.123

https://docs.safe.com/fme/2021.1/html/FME_Desktop_Documentation/FME_Transformers/Transformers/stringformatter.htm

example


Reply