For unary arithmetic expressions, say -column, the constructed AST is modified to create a binary expression where column is multiplied by -1. So, -column is transformed to -1 * column. Instead we should just create a unary expressionfunction call node. We are already doing that for NOT unary expressions, like NOT column.
For unary arithmetic expressions, say
-column
, the constructed AST is modified to create a binary expression wherecolumn
is multiplied by-1
. So,-column
is transformed to-1 * column
. Instead we should just create a unary expressionfunction
call node. We are already doing that forNOT
unary expressions, likeNOT column
.