The first plus sign is interpreted as an addition operator. Each of the remaining plus signs is interpreted as a unary plus operator:
1 ++ 2 means 1 + (+2)
1 +++ 2 means 1 + (+(+2))
It's very common in programming languages to have this unary plus operator, though it's rarely used in SQL as it doesn't actually do anything.
Although a unary plus can appear before any numeric expression, it performs no operation on the value returned from the expression. Specifically, it will not return the positive value of a negative expression.
The unary plus operator is mentioned in the SQL-92 standard.
As well as the usual arithmetic operators, plus, minus, times, divide, unary plus, and unary minus, there are the following functions that return numbers: ...
While unary plus isn't all that useful, it has a more useful companion: unary minus. It is also known as the negative operator.
SELECT -(expression), ...
-- ^ unary minus
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…