Question
2
Replies
625
Views
Posted: April 27, 2018
Last activity: November 6, 2018
Integer Divide Results are Rounded...
I generally like to avoid scripts if I can, but I wanted to do some integer arithmetic, and found that the result of an integer divide are being rounded! The result of an "a / 3" when a=2 is 1. And there doesn't seem to be any way to force it to be a 0. This is something that was resolved decades ago in the c language with the introduction of "\" for integer divides. It would be nice if Pega would implement that so we do integer arithmetic without scripts.
In the properties window for the Numeric Expression block, there is a property called Decimals which will set the number of digits after the decimal point.