Calculation Error in DQL

I won’t call this a bug. It really depends on how the expression is interpreted and in which order.
In this case, following the BODMAS rule, the division takes place before multiplication. And due to integer division (100/8) being equal to 12 we get the above difference.

There is no universal convention on whether to use the BODMAS or the PEMDAS rule and using any of the two is going to result in different answers for ambiguous expressions like 4*100/8 .

References:
https://math.berkeley.edu/~gbergman/misc/numbers/ord_ops.html