Evaluating Expressions WIth Max Int Values

Evaluating Expressions WIth Max Int Values

Comments

  • Is there a way to accurately add numbers with 10 or more digits without the sum rounding out?

  • Hi,
    The Max Int value is 2147483647 (which is 10 digits). When adding numbers up to this amount they are treated as integers and will evaluate properly. For any number greater then 2147483647 you will have to treat it as a decimal. So in order to prevent a result of 10 digits or greater from rounding out, you will have to pass the numbers you wish to add as decimals. To accomplish this use the Evaluate Dynamic Expression Step and pass an expression into the inputs. For example 9999999999[b].00[/b] + 9999999999[b].00[/b]" could be passed into the expression under the inputs. The output of that step should be 19999999998 which is an accurate result. However if you were to write the expression without the decimals (9999999999 + 9999999999) then you will see the output was rounded to 20000000000 which is not the desired result.

    For help on using the Evaluate Dynamic Expression Step:
    [url=http://documentation.decisions.com/evaluate-dynamic-expression/]http://documentation.decisions.com/evaluate-dynamic-expression/[/url]

    Thanks

Sign In or Register to comment.