Mashables and Mashups : Mashups in EMML : Advanced Mashup Techniques : Converting Numbers in Floating Point Notation
Converting Numbers in Floating Point Notation
The results of calculations in EMML using XPath expressions can end up in floating point notation, such as 1.625E10. To convert floating point numbers back to decimals, simply use the xs:decimal XPath function. For example:

...
<assign fromexpr="$total * $factor" outputvariable="$largeNumber"/>
<if condition="contains(string($largeNumber,’E’))">
<assign fromexpr="xs:decimal($largeNumber)" outputvariable="$largeNumber"/>
</if>
...

Copyright © 2013-2016 Software AG, Darmstadt, Germany.

Product LogoContact Support   |   Community   |   Feedback