Andrew Dunstan <andrew.duns...@2ndquadrant.com> writes: > Or we could possibly call the function and then turn a result of -0 into 0?
But -0 is the correct output if the input is -0. So that approach requires distinguishing -0 from 0, which is annoyingly difficult. regards, tom lane