I need to check whether all numbers are the same. The values are coming from different columns. The signiture should allow to put any amount of columns (like the COALESCE(...)
method)
SELECT equality(42, 42, 42)
should return true
and
SELECT equality(23, 42, 133)
should return false
.
Is there a nice way to code this?
At time i did it like this:
SELECT (x1 = x2 AND x2 = x3);
But i hope there is a more elegant way.